SquircleSpace / shcl

SHell in Common Lisp
Apache License 2.0
318 stars 17 forks source link

Empty input lines are no good #15

Closed phmarek closed 6 years ago

phmarek commented 6 years ago
$ true | ./shcl 
$ echo | ./shcl 

debugger invoked on a SHCL/CORE/SHELL-FORM::UNBOUND-SHELL-FORM-TRANSLATOR in thread
#<THREAD "main thread" RUNNING {10006905B3}>:
  Symbol TRUTHY-EXIT-INFO is unbound in namespace SHELL-FORM-TRANSLATOR

Type HELP for debugger help, or (SB-EXT:EXIT) to exit from SBCL.

restarts (invokable by number or by possibly-abbreviated name):
  0: [USE-VALUE] USE-VALUE
  1: [IGNORE   ] IGNORE
  2: [DIE      ] SHCL/SHELL/MAIN::DIE
  3: [ABORT    ] Exit from the current thread.

((:METHOD SHCL/CORE/SHELL-FORM::TRANSLATE-SHELL-FORM (CONS T)) (SHCL/CORE/EXIT-INFO:TRUTHY-EXIT-INFO) #<NULL-LEXENV>) [fast-method]
   source: (SYMBOL-SHELL-FORM-TRANSLATOR (CAR FORM))
0] 3

Ie. an empty line, followed by EOF (Ctrl-D interactively), gives this error.

SquircleSpace commented 6 years ago

D'oh. Good catch!

SquircleSpace commented 6 years ago

Should be fixed now. Thanks!