cs: fix handling of an empty command-line argument

This commit is contained in:
Matthew Flatt 2019-12-05 05:43:31 -07:00
parent 1f92e98590
commit c93693169a

View File

@ -558,8 +558,8 @@
(loop (cons (cadr args) (cons (car args) (cddr args))))])]
[else
(cond
[(and (eqv? (string-ref arg 0) #\-)
(> (string-length arg) 1))
[(and (> (string-length arg) 1)
(eqv? (string-ref arg 0) #\-))
(cond
[(and (> (string-length arg) 2)
(not (eqv? (string-ref arg 1) #\-)))