Removed 'append' from runtime lib since Daniel Gackle provided a more concise macro...
[clinton/parenscript.git] / src / deprecated-interface.lisp
index 68f6550..dc1f2f6 100644 (file)
 
 (defmacro defun-js (old-name new-name args &body body)
   `(defun ,old-name ,args
-    ,(when (and (stringp (car body)) (< 1 (length body))) ;; docstring
+    ,(when (and (stringp (car body)) (< 1 (length body))) ; docstring
            (car body))
     (warn-deprecated ',old-name ',new-name)
     ,@body))
 
-;;; DEPRECATED INTERFACE ;;;
+;;; DEPRECATED INTERFACE
+
+(defmacro define-script-symbol-macro (name &body body)
+  (warn-deprecated 'define-script-symbol-macro 'define-ps-symbol-macro)
+  `(define-ps-symbol-macro ,name ,@body))
 
 (defun js-equal (ps-form1 ps-form2)
   (warn-deprecated 'js-equal)
 
 (defun-js js* ps* (&rest args)
   (apply #'ps* args))
+
+(defun-js compile-script ps1* (ps-form &key (output-stream nil))
+  "Compiles the Parenscript form PS-FORM into Javascript.
+If OUTPUT-STREAM is NIL, then the result is a string; otherwise code
+is output to the OUTPUT-STREAM stream."
+  (format output-stream "~A" (ps1* ps-form)))
+
+(defun-js symbol-to-js symbol-to-js-string (symbol)
+  (symbol-to-js-string symbol))