cl: Dump a core image to improve startup times.
[fringe] / cl-fringe.lisp
index 0081ee3..7386c38 100644 (file)
                                       (iterate-fringe (parse-tree b))))))))
 
 #+cl-launch
-(flet ((bail (format args)
-        (format *error-output* "~A: ~?~%"
-                (cl-launch:getenv "CL_LAUNCH_FILE") format args)
-        (cl-launch:quit 1)))
-  (handler-case
-      (main cl-launch:*arguments*)
-    (simple-error (err)
-      (bail (simple-condition-format-control err)
-           (simple-condition-format-arguments err)))
-    (error (err)
-      (bail "~A" err))))
+(defun launch ()
+  (flet ((bail (format args)
+          (format *error-output* "~A: ~?~%"
+                  (cl-launch:getenv "CL_LAUNCH_FILE") format args)
+          (cl-launch:quit 1)))
+    (handler-case
+       (main cl-launch:*arguments*)
+      (simple-error (err)
+       (bail (simple-condition-format-control err)
+             (simple-condition-format-arguments err)))
+      (error (err)
+       (bail "~A" err)))))
 
 ;;;----- That's all, folks --------------------------------------------------