diff --git a/lisp/ob.el b/lisp/ob.el index eec88f0e3..d20205f6b 100644 --- a/lisp/ob.el +++ b/lisp/ob.el @@ -224,7 +224,8 @@ Returns a list (lambda (ref) (cons :var ref)) (mapcar (lambda (var) ;; check that each variable is initialized - (unless (string-match ".+=.+" var) + (if (string-match ".+=.+" var) + var (error "variable \"%s\"%s must be assigned a default value" var (if name (format " in block \"%s\"" name) ""))))