Fix handling of unknown options in set

* geesh/built-ins/set.scm (main): Continue processing options as new
arguments (i.e., 'set -- ...') after encountering an unknown option.
This commit is contained in:
Timothy Sample 2018-12-04 10:09:38 -05:00
parent 2bcef52895
commit bc7e876f6d
1 changed files with 1 additions and 4 deletions

View File

@ -85,10 +85,7 @@
((#\+ (? option-letter? chr))
(setopt! (assoc-ref *option-letters* chr) #f)
(loop args))
(_ (format (current-error-port)
"~a: set: invalid option ~s~%"
(car (program-arguments)) op)
EXIT_FAILURE)))
(_ (loop (cons* "--" op args)))))
(_ (format (current-error-port)
"~a: set: invalid options ~s~%"
(car (program-arguments)) args)