From: David Vázquez Date: Fri, 26 Apr 2013 22:02:31 +0000 (+0100) Subject: Revert "Simplify literal object dumping" X-Git-Url: http://repo.macrolet.net/gitweb/?p=jscl.git;a=commitdiff_plain;h=e735c93194ed69c369d95a849b27135f3f4c2444 Revert "Simplify literal object dumping" This reverts commit bf4fd5a5239efe4931e03f7174a0907aba6f07ef. Conflicts: src/compiler.lisp --- diff --git a/jscl.lisp b/jscl.lisp index 51a6ba6..3a70e2e 100644 --- a/jscl.lisp +++ b/jscl.lisp @@ -64,7 +64,7 @@ (defun bootstrap () (setq *environment* (make-lexenv)) - (setq *literal-table* nil) + (setq *literal-symbols* nil) (setq *variable-counter* 0 *gensym-counter* 0 *literal-counter* 0 diff --git a/src/boot.lisp b/src/boot.lisp index 0af19f4..c21fa26 100644 --- a/src/boot.lisp +++ b/src/boot.lisp @@ -680,9 +680,7 @@ `((,(ecase (car c) (integer 'integerp) (cons 'consp) - (symbol 'symbolp) (string 'stringp) - (array 'arrayp) (atom 'atom) (null 'null)) ,value) diff --git a/src/compiler.lisp b/src/compiler.lisp index 4d1cdbd..ee4514c 100644 --- a/src/compiler.lisp +++ b/src/compiler.lisp @@ -527,7 +527,7 @@ output)) -(defvar *literal-table* nil) +(defvar *literal-symbols* nil) (defvar *literal-counter* 0) (defun genlit () @@ -578,6 +578,7 @@ (toplevel-compilation (code "var " v " = " c)) v))))))) + (define-compilation quote (sexp) (literal sexp)) diff --git a/src/toplevel.lisp b/src/toplevel.lisp index 2c19dd7..6fb2569 100644 --- a/src/toplevel.lisp +++ b/src/toplevel.lisp @@ -98,8 +98,8 @@ (ls-compile `(progn ,@(mapcar (lambda (s) `(%intern-symbol (%js-vref ,(cdr s)))) - *literal-table*) - (setq *literal-table* ',*literal-table*) + *literal-symbols*) + (setq *literal-symbols* ',*literal-symbols*) (setq *variable-counter* ,*variable-counter*) (setq *gensym-counter* ,*gensym-counter*) (setq *block-counter* ,*block-counter*)))))