From 7fbb730d9caa769553ffb7a6b49ed2b7eb401d4d Mon Sep 17 00:00:00 2001 From: David Vazquez Date: Mon, 17 Dec 2012 13:34:37 +0000 Subject: [PATCH] Define bootstrap function --- lispstrack.lisp | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/lispstrack.lisp b/lispstrack.lisp index 8481fb7..70f8f6a 100644 --- a/lispstrack.lisp +++ b/lispstrack.lisp @@ -523,15 +523,14 @@ (setq *toplevel-compilations* nil)))) #+common-lisp -(defun ls-compile-file (filename output) - (with-open-file (in filename) - (with-open-file (out output :direction :output :if-exists :supersede) - (loop - for x = (ls-read in) - until (eq x *eof*) - for compilation = (ls-compile-toplevel x) - when compilation do (write-line (concat compilation "; ") out))))) - -;;; Testing -(defun compile-test () - (ls-compile-file "test.lisp" "test.js")) +(progn + (defun ls-compile-file (filename output) + (with-open-file (in filename) + (with-open-file (out output :direction :output :if-exists :supersede) + (loop + for x = (ls-read in) + until (eq x *eof*) + for compilation = (ls-compile-toplevel x) + when compilation do (write-line (concat compilation "; ") out))))) + (defun bootstrap () + (ls-compile-file "lispstrack.lisp" "lispstrack.js"))) -- 1.7.10.4