Made progn expressions with a single statement print as that statement alone (without...
[clinton/parenscript.git] / src / package.lisp
index ca9d6f0..1170041 100644 (file)
@@ -1,10 +1,7 @@
 (in-package :cl-user)
-;;;; Package definitions for the Parenscript 
-;; #: 
 
-(eval-when (:compile-toplevel :load-toplevel)
-  ;; exports shared between PARENSCRIPT and PARENSCRIPT.JAVASCRIPT
-  (defparameter *shared-symbols-ps-js*
+(eval-when (:compile-toplevel :load-toplevel :execute)
+  (defparameter *parenscript-lang-exports*
     '(
       ;; literals
       #:t
@@ -42,7 +39,6 @@
       #:\|\| #:or
       #:>>= #:<<=
       #:*= #:/= #:%= #:+= #:\&= #:^= #:\|= #:~=
-      #:++ #:--
       #:1+ #:1-
       #:incf #:decf
       
       #:instanceof
       #:new
       
-      ;; assignment
+      ;; assignment and binding
       #:setf
+      #:defaultf
+      #:defsetf
+      #:let
       
       ;; variables
       #:defvar
       #:regex
       
       ;; conditional compilation (IE)
-      #:cc-if)
-    "Symbols exported from both the Parenscript and Javascript packages 
-that are also valid as Parenscript symbols for the corresponding script packages."))
-
-(eval-when (:compile-toplevel :load-toplevel :execute)
-  (defparameter *parenscript-lang-exports*
-    (append 
-     *shared-symbols-ps-js*
-     '(
-       ;; function definition
-       #:defun
-       #:lambda
+      #:cc-if
        
-       ;; lambda lists
-       #:&key
-       #:&rest
-       #:&body
-       #:&optional
-       #:&aux
-       #:&environment
-       #:&key-object
-       #:optional-args
+      ;; function definition
+      #:defun
+      #:lambda
+       
+      ;; lambda lists
+      #:&key
+      #:&rest
+      #:&body
+      #:&optional
+      #:&aux
+      #:&environment
+      #:&key-object
 
-       ;; slot access
-       #:with-slots
-       #:slot-value
+      ;; slot access
+      #:with-slots
+      #:slot-value
 
-       ;; macros
-       #:macrolet
-       #:symbol-macrolet
-       #:define-symbol-macro
-       #:define-script-symbol-macro
-       #:defmacro
-       
-       ;; lisp eval
-       #:lisp
+      ;; macros
+      #:macrolet
+      #:symbol-macrolet
+      #:define-symbol-macro
+      #:define-script-symbol-macro
+      #:defmacro
        
-       ;; assignment
-       #:setf
-       #:defaultf
-
-       #:let
+      ;; lisp eval
+      #:lisp
        
-       ;; iteration
-       #:do
-       #:dotimes
-       #:dolist
-       #:doeach
-       #:while
+      ;; iteration
+      #:do
+      #:dotimes
+      #:dolist
+      #:doeach
+      #:while
        
-       ;; v v v STUFF WE SHOULD PROBABLY MOVE TO OTHER LIBS v v v
+      ;; v v v STUFF WE SHOULD PROBABLY MOVE TO OTHER LIBS v v v
        
-       ;; CSS
-       #:css
-       #:css-to-string
-       #:css-inline
-       #:css-file
+      ;; CSS
+      #:css
+      #:css-to-string
+      #:css-inline
+      #:css-file
 
-       ;; html generator for javascript
-       #:html
+      ;; html generator for javascript
+      #:ps-html
 
-       ;; utils
-       #:do-set-timeout
-       ))
-    "List of (uninterned) symbols. Contains all symbols considerred
-part of the Parenscript language.  These should be exported within
-both the Lisp package and the script package for Parenscript."))
+      ;; utils
+      #:do-set-timeout
+      ))
+  "All symbols considerred part of the Parenscript language.")
 
 (defpackage :parenscript
   (:use :common-lisp)
   (:nicknames :js :ps)
-  #.(cons :export *shared-symbols-ps-js*)
   #.(cons :export *parenscript-lang-exports*)
+
+  ;;; symbols that form the interface to the Parenscript compiler
   (:export
    ;; compiler
    #:compile-script
    #:ps
    #:ps*
+   #:ps-inline
+   #:ps-inline*
    
    ;; for parenscript macro definition within lisp
    #:defpsmacro
@@ -189,6 +175,11 @@ both the Lisp package and the script package for Parenscript."))
    #:with-ps-gensyms
    #:*ps-gensym-counter*
 
+   ;; naming and namespaces
+   #:*obfuscate-identifiers*
+   #:*package-prefix-style*
+   #:ps-package-prefix
+
    ;; deprecated interface
    #:gen-js-name
    #:gen-js-name-string
@@ -203,4 +194,3 @@ both the Lisp package and the script package for Parenscript."))
    #:js
    #:js*
    ))
-