From 419a88b7d6a8c0248c17c47a9a46b0aab0b5936f Mon Sep 17 00:00:00 2001 From: dos-reis Date: Fri, 11 Jul 2008 00:10:17 +0000 Subject: * interp/compiler.boot (compQuote): Restrict quoting to literal symbols. * algebra/any.spad.pamphlet: Use nil for empty list. * algebra/boolean.spad.pamphlet: Fix quoting. --- src/interp/compiler.boot | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/interp') diff --git a/src/interp/compiler.boot b/src/interp/compiler.boot index 10657288..1d9686bc 100644 --- a/src/interp/compiler.boot +++ b/src/interp/compiler.boot @@ -828,7 +828,11 @@ compConstruct(form is ["construct",:l],m,e) == (T:= compVector(l,["Vector",CADR y],e)) and (T':= convert(T,m)) => return T' -compQuote(expr,m,e) == [expr,m,e] +++ Compile a literal (quoted) symbol. +compQuote: (%Form,%Mode,%Env) -> %Maybe %Triple +compQuote(expr,m,e) == + expr is ["QUOTE",x] and SYMBOLP x => convert([expr,$Symbol,e],m) + stackAndThrow('"%1b is not a literal symbol.",[x]) compList: (%Form,%Mode,%Env) -> %Maybe %Triple compList(l,m is ["List",mUnder],e) == -- cgit v1.2.3