diff --git a/beautiful-racket-demo/basic-demo-2/go.rkt b/beautiful-racket-demo/basic-demo-2/go.rkt index d29f19d..5f97ac5 100644 --- a/beautiful-racket-demo/basic-demo-2/go.rkt +++ b/beautiful-racket-demo/basic-demo-2/go.rkt @@ -15,7 +15,7 @@ (b-goto num-expr))) (define (b-return) - (unless (not (empty? return-ccs)) + (when (empty? return-ccs) (raise-line-error "return without gosub")) (define top-cc (pop! return-ccs)) (top-cc (void))) diff --git a/beautiful-racket-demo/basic-demo-3/go.rkt b/beautiful-racket-demo/basic-demo-3/go.rkt index d29f19d..5f97ac5 100644 --- a/beautiful-racket-demo/basic-demo-3/go.rkt +++ b/beautiful-racket-demo/basic-demo-3/go.rkt @@ -15,7 +15,7 @@ (b-goto num-expr))) (define (b-return) - (unless (not (empty? return-ccs)) + (when (empty? return-ccs) (raise-line-error "return without gosub")) (define top-cc (pop! return-ccs)) (top-cc (void)))