From 4d1e0c96a42dbb4f7375514241c1c520e7dad00b Mon Sep 17 00:00:00 2001 From: Timothy Sample Date: Fri, 21 Dec 2018 20:40:52 -0500 Subject: [PATCH] shell: Make 'continue' work in while loops. * geesh/shell.scm (sh:while): Use 'call-with-continue' when invoking the body thunk. --- geesh/shell.scm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/geesh/shell.scm b/geesh/shell.scm index 50b76fd..dbc7a01 100644 --- a/geesh/shell.scm +++ b/geesh/shell.scm @@ -353,7 +353,7 @@ of each thunk sent to the input of the next thunk." (without-errexit test-thunk) (cond ((= (get-status) 0) - (thunk) + (call-with-continue thunk) (loop (get-status))) (else (set-status! last-status)))))))