X-Git-Url: http://repo.macrolet.net/gitweb/?a=blobdiff_plain;f=src%2Ftoplevel.lisp;h=7dddf6e5f6bbc4632bcac269edb2e2209f72d7b3;hb=916539de6153df7b4f6838c5e03ef420a890256c;hp=a3965548895c3a190d15fbd63b5e568014fb3da7;hpb=75633282e9f9f4b0b1c74bdcf27f693988e079fc;p=jscl.git diff --git a/src/toplevel.lisp b/src/toplevel.lisp index a396554..7dddf6e 100644 --- a/src/toplevel.lisp +++ b/src/toplevel.lisp @@ -16,9 +16,10 @@ ;; You should have received a copy of the GNU General Public License ;; along with JSCL. If not, see . +(/debug "loading toplevel.lisp!") (defun eval (x) - (js-eval (ls-compile-toplevel x t))) + (js-eval (compile-toplevel x t))) (defvar * nil) (defvar ** nil) @@ -249,14 +250,16 @@ (setq *package* *user-package*) +(defvar *root* (%js-vref "window")) + ;;; Set some external entry point to the Lisp implementation to the ;;; console. It would not be necessary when FFI is finished. (let ((*root* #j:lisp)) (setf #j:read #'ls-read-from-string) (setf #j:print #'prin1-to-string) (setf #j:eval #'eval) - (setf #j:compile (lambda (s) (ls-compile-toplevel s t))) + (setf #j:compile (lambda (s) (compile-toplevel s t))) (setf #j:evalString (lambda (str) (eval (ls-read-from-string str)))) (setf #j:evalInput (lambda (str) (eval-interactive (ls-read-from-string str)))) - (setf #j:compileString (lambda (str) (ls-compile-toplevel (ls-read-from-string str) t)))) + (setf #j:compileString (lambda (str) (compile-toplevel (ls-read-from-string str) t))))