~ubuntu-branches/debian/squeeze/maxima/squeeze

« back to all changes in this revision

Viewing changes to src/init-cl.lisp

  • Committer: Bazaar Package Importer
  • Author(s): Camm Maguire
  • Date: 2006-10-18 14:52:42 UTC
  • mto: (1.1.5 upstream)
  • mto: This revision was merged to the branch mainline in revision 4.
  • Revision ID: james.westby@ubuntu.com-20061018145242-vzyrm5hmxr8kiosf
ImportĀ upstreamĀ versionĀ 5.10.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
;********************************************************
2
 
; file:        init-cl.lisp                              
3
 
; description: Initialize Maxima                         
4
 
; date:        Wed Jan 13 1999 - 20:27                   
5
 
; author:      Liam Healy <Liam.Healy@nrl.navy.mil>      
6
 
;********************************************************
 
1
;;********************************************************
 
2
;; file:        init-cl.lisp                              
 
3
;; description: Initialize Maxima                         
 
4
;; date:        Wed Jan 13 1999 - 20:27                   
 
5
;; author:      Liam Healy <Liam.Healy@nrl.navy.mil>      
 
6
;;********************************************************
7
7
 
8
8
(in-package :maxima)
9
 
(use-package "COMMAND-LINE")
 
9
 
10
10
;;; An ANSI-CL portable initializer to replace init_max1.lisp
11
11
 
12
12
;;; Locations of various types of files. These variables are discussed
20
20
(defvar *maxima-sharedir*)
21
21
(defvar *maxima-symdir*)
22
22
(defvar *maxima-srcdir*)
23
 
(defvar *maxima-demodir*)
24
 
(defvar *maxima-testsdir*)
25
23
(defvar *maxima-docdir*)
26
24
(defvar *maxima-infodir*)
27
25
(defvar *maxima-htmldir*)
28
 
(defvar *maxima-plotdir*)
29
26
(defvar *maxima-layout-autotools*)
30
27
(defvar *maxima-userdir*)
 
28
(defvar *maxima-tempdir*)
 
29
(defvar *maxima-lang-subdir*)
 
30
 
 
31
(defmvar $maxima_tempdir)
 
32
(putprop '$maxima_tempdir 'shadow-string-assignment 'assign)
 
33
(putprop '$maxima_tempdir '*maxima-tempdir* 'lisp-shadow)
 
34
 
 
35
(defmvar $maxima_userdir)
 
36
(putprop '$maxima_userdir 'shadow-string-assignment 'assign)
 
37
(putprop '$maxima_userdir '*maxima-userdir* 'lisp-shadow)
 
38
 
 
39
(defun shadow-string-assignment (var value)
 
40
  (cond
 
41
    ((mstringp value)
 
42
     (set (get var 'lisp-shadow) (maybe-invert-string-case (symbol-name (stripdollar value))))
 
43
     value)
 
44
    ((stringp value)
 
45
     (set (get var 'lisp-shadow) value)
 
46
     value)
 
47
    (t
 
48
      (merror "Attempt to assign a non-string to ~:M" var))))
31
49
 
32
50
(defun print-directories ()
33
51
  (format t "maxima-prefix=~a~%" *maxima-prefix*)
43
61
  (format t "maxima-plotdir=~a~%" *maxima-plotdir*)
44
62
  (format t "maxima-layout-autotools=~a~%" *maxima-layout-autotools*)
45
63
  (format t "maxima-userdir=~a~%" *maxima-userdir*)
 
64
  (format t "maxima-tempdir=~a~%" *maxima-tempdir*)
 
65
  (format t "maxima-lang-subdir=~a~%" *maxima-lang-subdir*)
46
66
  ($quit))
47
67
 
48
68
(defvar *maxima-lispname* #+clisp "clisp"
49
69
        #+cmu "cmucl"
 
70
        #+scl "scl"
50
71
        #+sbcl "sbcl"
51
72
        #+gcl "gcl"
52
 
        #+allegro "acl6"
 
73
        #+allegro "acl"
53
74
        #+openmcl "openmcl"
54
 
        #-(or clisp cmu sbcl gcl allegro openmcl) "unknownlisp")
55
 
 
56
 
(defun combine-path (list)
57
 
  (let ((result (first list)))
58
 
    (mapc #'(lambda (x) 
59
 
                (setf result 
60
 
                      (concatenate 'string result "/" x))) (rest list))
61
 
    result))
 
75
        #-(or clisp cmu scl sbcl gcl allegro openmcl) "unknownlisp")
 
76
 
 
77
 
62
78
 
63
79
(defvar $file_search_lisp nil
64
80
  "Directories to search for Lisp source code.")
70
86
  "Directories to search for demos.")
71
87
 
72
88
(defvar $file_search_usage nil)
 
89
 
 
90
(defvar $file_search_tests nil
 
91
  "Directories to search for maxima test suite")
 
92
 
73
93
(defvar $chemin nil)
74
94
 
75
 
#+gcl
76
 
(defun maxima-getenv (envvar)
77
 
  (si::getenv envvar))
78
 
 
79
 
#+allegro
80
 
(defun maxima-getenv (envvar)
81
 
  (system:getenv envvar))
82
 
 
83
 
#+cmu
84
 
(defun maxima-getenv (envvar)
85
 
  (cdr (assoc envvar ext:*environment-list* :test #'string=)))
86
 
 
87
 
#+sbcl
88
 
(defun maxima-getenv (envvar)
89
 
  (sb-ext:posix-getenv envvar))
90
 
 
91
 
#+clisp
92
 
(defun maxima-getenv (envvar)
93
 
  (ext:getenv envvar))
94
 
 
95
 
#+mcl
96
 
(defun maxima-getenv (envvar)
97
 
  (ccl::getenv envvar))
98
95
 
99
96
(defun maxima-parse-dirstring (str)
100
97
  (let ((sep "/"))
105
102
                 (let ((dev (pathname-device str)))
106
103
                   (if (consp dev)
107
104
                       (setf dev (first dev)))
108
 
                   (if (and dev (not (string= dev "")))
 
105
                   (if (and dev (not (eq dev :unspecific))
 
106
                            (not (string= dev "")))
109
107
                       (concatenate 'string
110
108
                                    (string-right-trim 
111
109
                                     ":" dev) ":")
112
 
                     ""))
 
110
                       ""))
113
111
                 "/"
114
112
                 (combine-path
115
113
                  (rest (pathname-directory str))))))
120
118
        (datadir)
121
119
        (infodir)
122
120
        (package-version (combine-path (list *autoconf-package*
123
 
                                         *autoconf-version*)))
 
121
                                             *autoconf-version*)))
124
122
        (binary-subdirectory (concatenate 'string 
125
123
                                          "binary-" *maxima-lispname*)))
126
124
    (if maxima-prefix-env
199
197
                  "/tmp")))
200
198
    (combine-path (list (maxima-parse-dirstring base-dir) maxima-dir))))
201
199
 
 
200
(defun default-tempdir ()
 
201
  (let ((home-env (maxima-getenv "HOME"))
 
202
        (base-dir ""))
 
203
    (setf base-dir 
 
204
          (if (and home-env (string/= home-env ""))
 
205
              (if (string= home-env "c:\\")
 
206
                  "c:\\user\\"
 
207
                  home-env)
 
208
              (if (string= *autoconf-win32* "true")
 
209
                  "c:\\user\\"
 
210
                  "/tmp")))
 
211
    (maxima-parse-dirstring base-dir)))
 
212
 
 
213
(defun set-locale ()
 
214
  (let (locale language territory codeset)
 
215
    (setq cl-info::*index-name* "index")
 
216
    (unless  (setq *maxima-lang-subdir* (maxima-getenv "MAXIMA_LANG_SUBDIR"))
 
217
        (setq locale (or (maxima-getenv "LC_ALL")
 
218
                         (maxima-getenv "LC_MESSAGES")
 
219
                         (maxima-getenv "LANG")))
 
220
        (cond
 
221
            ((null locale) 
 
222
                (setq *maxima-lang-subdir* nil))
 
223
            ((zl-member locale '("C" "POSIX" "c" "posix"))               
 
224
                (setq *maxima-lang-subdir* nil))
 
225
            (t  (when (eql (position #\. locale) 5)
 
226
                    (setq codeset (string-downcase (subseq locale 6))))
 
227
                (when (eql (position #\_ locale) 2)
 
228
                    (setq territory (string-downcase (subseq locale 3 5))))
 
229
                (setq language (string-downcase (subseq locale 0 2)))
 
230
                ;; Set *maxima-lang-subdir* only for known languages.
 
231
                ;; Extend procedure below as soon as new translation
 
232
                ;; is available. 
 
233
                (cond
 
234
                    ;; English
 
235
                    ((equal language "en")
 
236
                        (setq *maxima-lang-subdir* nil))
 
237
                    ;; Latin-1 aka iso-8859-1 languages 
 
238
                    ((zl-member language '("es" "pt"))
 
239
                      (if (zl-member codeset '("utf-8" "utf8"))
 
240
                            (setq *maxima-lang-subdir* (concatenate 'string language ".utf8"))
 
241
                            (setq *maxima-lang-subdir* language)))
 
242
                    (t  (setq *maxima-lang-subdir* nil)))
 
243
                ;; Translation of the word "Index" to match node "Fuction and Variable Index"
 
244
                (cond
 
245
                    ((equal language "es")
 
246
                        (setq cl-info::*index-name* (format nil "~andice" (code-char #xCD))))
 
247
                    ((equal language "pt")
 
248
                        (setq cl-info::*index-name* (format nil "~andice" (code-char #xCD)))) 
 
249
                )
 
250
                ;; Additional language-dependent pattern to match nodes such as 
 
251
                ;;  -- Function: foo (x)
 
252
                ;; or
 
253
                ;;  -- Option variable: bar
 
254
                (cond 
 
255
                    ;; This pattern is suitable for all Latin-1 (aka ISO-8859-1) langages
 
256
                    ((zl-member language '("es" "pt"))
 
257
                        (setq cl-info::*extra-chars* (format nil "~a-~a" (code-char #xC0) (code-char #xFF))))
 
258
                )
 
259
            )))
 
260
   (setq cl-info::*lang-subdir* *maxima-lang-subdir*)))    
 
261
 
202
262
(defun set-pathnames ()
203
263
  (let ((maxima-prefix-env (maxima-getenv "MAXIMA_PREFIX"))
204
264
        (maxima-layout-autotools-env (maxima-getenv "MAXIMA_LAYOUT_AUTOTOOLS"))
205
 
        (maxima-userdir-env (maxima-getenv "MAXIMA_USERDIR")))
 
265
        (maxima-userdir-env (maxima-getenv "MAXIMA_USERDIR"))
 
266
        (maxima-tempdir-env (maxima-getenv "MAXIMA_TEMPDIR")))
206
267
    ;; MAXIMA_DIRECTORY is a deprecated substitute for MAXIMA_PREFIX
207
268
    (if (not maxima-prefix-env)
208
269
        (setq maxima-prefix-env (maxima-getenv "MAXIMA_DIRECTORY")))
219
280
        (set-pathnames-without-autoconf maxima-prefix-env))
220
281
    (if maxima-userdir-env
221
282
        (setq *maxima-userdir* (maxima-parse-dirstring maxima-userdir-env))
222
 
        (setq *maxima-userdir* (default-userdir))))
 
283
        (setq *maxima-userdir* (default-userdir)))
 
284
    (if maxima-tempdir-env
 
285
        (setq *maxima-tempdir* (maxima-parse-dirstring maxima-tempdir-env))
 
286
        (setq *maxima-tempdir* (default-tempdir)))
 
287
 
 
288
    ; Assign initial values for Maxima shadow variables
 
289
    (setq $maxima_userdir *maxima-userdir*)
 
290
    (setf (gethash '$maxima_userdir *variable-initial-values*) *maxima-userdir*)
 
291
    (setq $maxima_tempdir *maxima-tempdir*)
 
292
    (setf (gethash '$maxima_tempdir *variable-initial-values*) *maxima-tempdir*))
223
293
  
224
294
  (let* ((ext #+gcl "o"
225
 
              #+cmu (c::backend-fasl-file-type c::*target-backend*)
 
295
              #+(or cmu scl) (c::backend-fasl-file-type c::*target-backend*)
226
296
              #+sbcl "fasl"
227
297
              #+clisp "fas"
228
298
              #+allegro "fasl"
229
299
              #+(and openmcl darwinppc-target) "dfsl"
230
300
              #+(and openmcl linuxppc-target) "pfsl"
231
 
              #-(or gcl cmu sbcl clisp allegro openmcl)
 
301
              #-(or gcl cmu scl sbcl clisp allegro openmcl)
232
302
              "")
233
303
         (lisp-patterns (concatenate 
234
304
                         'string "###.{"
236
306
         (maxima-patterns "###.{mac,mc}")
237
307
         (demo-patterns "###.{dem,dm1,dm2,dm3,dmt}")
238
308
         (usage-patterns "##.{usg,texi}")
239
 
         (share-subdirs "{affine,algebra,calculus,combinatorics,contrib,contrib/nset,contrib/pdiff,diffequations,graphics,integequations,integration,macro,matrix,misc,numeric,physics,simplification,specfunctions,sym,tensor,trigonometry,utils,vector}"))
 
309
         (share-subdirs-list
 
310
       '("affine"
 
311
         "algebra"
 
312
         "algebra/charsets"
 
313
         "algebra/solver"
 
314
         "calculus"
 
315
         "combinatorics"
 
316
         "contrib"
 
317
         "contrib/boolsimp"
 
318
         "contrib/descriptive"
 
319
         "contrib/diffequations"
 
320
         "contrib/diffequations/tests"
 
321
         "contrib/distrib"
 
322
         "contrib/ezunits"
 
323
         "contrib/format"
 
324
         "contrib/gentran"
 
325
         "contrib/gentran/test"
 
326
         "contrib/Grobner"
 
327
         "contrib/lurkmathml"
 
328
         "contrib/maximaMathML"
 
329
         "contrib/mcclim"
 
330
         "contrib/numericalio"
 
331
         "contrib/pdiff"
 
332
         "contrib/prim"
 
333
         "contrib/rand"
 
334
         "contrib/sarag"
 
335
         "contrib/simplex"
 
336
         "contrib/simplex/Tests"
 
337
         "contrib/solve_rec"
 
338
         "contrib/state"
 
339
         "contrib/stringproc"
 
340
         "contrib/unit"
 
341
         "contrib/Zeilberger"
 
342
         "diffequations"
 
343
         "lbfgs"
 
344
         "linearalgebra"
 
345
         "integequations"
 
346
         "integration"
 
347
         "macro"
 
348
         "matrix"
 
349
         "misc"
 
350
         "numeric"
 
351
         "orthopoly"
 
352
         "physics"
 
353
         "simplification"
 
354
         "sym"
 
355
         "tensor"
 
356
         "tensor/tests"
 
357
         "trigonometry"
 
358
         "utils"
 
359
         "vector"))
 
360
     ; Smash the list of share subdirs into a string of the form "{affine,algebra,...,vector}" .
 
361
         (share-subdirs (format nil "{~{~A~^,~}}" share-subdirs-list)))
 
362
 
240
363
    (setq $file_search_lisp
241
364
          (list '(mlist)
242
365
                ;; actually, this entry is not correct.
265
388
                (combine-path (list *maxima-sharedir* share-subdirs
266
389
                                    usage-patterns))
267
390
                (combine-path (list *maxima-docdir* usage-patterns))))
 
391
    (setq $file_search_tests
 
392
          `((mlist) ,(combine-path (list *maxima-testsdir* maxima-patterns))))
268
393
    (setq $chemin
269
 
          (concatenate 'string *maxima-symdir* "/"))
270
 
    (setq cl-info::*info-paths* (list (concatenate 'string
271
 
                                                   *maxima-infodir* "/")))))
 
394
          (list '(mlist)
 
395
                (combine-path (list *maxima-symdir* lisp-patterns))
 
396
                (combine-path (list *maxima-symdir* maxima-patterns))))
 
397
    (setq cl-info::*info-paths* (list (concatenate 'string *maxima-infodir* "/")))
 
398
    ;; Share subdirs are not required here since all .info files are installed
 
399
    ;; in one directory *maxima-infodir* -- there is no info files in share.
 
400
    ;; vvzhy Jan 2, 2006
 
401
    ;(setq L (mapcar #'(lambda (x) (concatenate 'string *maxima-sharedir* "/" x "/")) share-subdirs-list))
 
402
    ;(setq cl-info::*info-paths* (append cl-info::*info-paths* L))
 
403
 
 
404
    ; Look for "foo.info" in share directory "foo".
 
405
    (loop for d in share-subdirs-list do
 
406
      (let ((name (if (find #\/ d) (unix-like-basename d) d)))
 
407
        (when (cl-info::file-search name cl-info::*info-paths* '("info") nil)
 
408
          #+debug (format t "SET-PATHNAMES: found an info file for share directory ~S~%" name)
 
409
          (nconc cl-info::*default-info-files* `(,(concatenate 'string name ".info"))))))))
272
410
 
273
411
(defun get-dirs (path)
274
412
  #+(or :clisp :sbcl)
282
420
    (if (equal (subseq pathstring (- len 1) len) "/")
283
421
        (progn (setf len (- len 1))
284
422
               (setf pathstring (subseq pathstring 0 len))))
285
 
    (subseq pathstring (+ (position #\/ pathstring :from-end t) 1) len)))
 
423
    (subseq pathstring (+ (or (position #\/ pathstring :from-end t) (position #\\ pathstring :from-end t)) 1) len)))
286
424
 
287
425
(defun unix-like-dirname (path)
288
426
  (let* ((pathstring (namestring path))
290
428
    (if (equal (subseq pathstring (- len 1) len) "/")
291
429
        (progn (setf len (- len 1))
292
430
               (setf pathstring (subseq pathstring 0 len))))
293
 
    (subseq pathstring 0 (position #\/ pathstring :from-end t))))
 
431
    (subseq pathstring 0 (or (position #\/ pathstring :from-end t) (position #\\ pathstring :from-end t)))))
294
432
 
295
433
(defun list-avail-action ()
296
434
  (let* ((maxima-verpkglibdir (if (maxima-getenv "MAXIMA-VERPKGLIBDIR")
325
463
        (setf lisp-string (unix-like-basename lisp))
326
464
        (when (search "binary-" lisp-string)
327
465
          (setf lisp-string (subseq lisp-string (length "binary-") 
328
 
                                  (length lisp-string)))
 
466
                                    (length lisp-string)))
329
467
          (format t "version ~a, lisp ~a~%" version-string lisp-string))))
330
468
    (bye)))
331
469
 
332
470
(defun process-maxima-args (input-stream batch-flag)
333
 
;    (format t "processing maxima args = ")
334
 
;    (mapc #'(lambda (x) (format t "\"~a\"~%" x)) (get-application-args))
335
 
;    (terpri)
 
471
  ;;    (format t "processing maxima args = ")
 
472
  ;;    (mapc #'(lambda (x) (format t "\"~a\"~%" x)) (get-application-args))
 
473
  ;;    (terpri)
336
474
  (let ((maxima-options nil))
337
475
    (setf maxima-options
338
476
          (list 
396
534
                           :action #'(lambda (file)
397
535
                                       (load file))
398
536
                           :help-string "Preload <lisp-file>.")
 
537
       (make-cl-option :names '("-q" "--quiet")
 
538
               :action #'(lambda () (declare (special *maxima-quiet*)) (setq *maxima-quiet* t))
 
539
               :help-string "Suppress Maxima start-up message.")
399
540
           (make-cl-option :names '("--disable-readline")
400
541
                           :action #'(lambda ()
401
542
                                       #+gcl
402
 
                                       (si::readline-off)))
 
543
                                       (si::readline-off))
 
544
                           :help-string "Disable readline support.")
403
545
           (make-cl-option :names '("-s" "--server")
404
546
                           :argument "<port>"
405
547
                           :action #'(lambda (port-string)
429
571
    (process-args (get-application-args) maxima-options))
430
572
  (values input-stream batch-flag))
431
573
 
432
 
(defun user::run ()
 
574
(defun cl-user::run ()
433
575
  "Run Maxima in its own package."
434
 
  (in-package "MAXIMA")
 
576
  (in-package :maxima)
435
577
  (setf *load-verbose* nil)
436
578
  (setf *debugger-hook* #'maxima-lisp-debugger)
437
579
  (let ((input-stream *standard-input*)
443
585
    
444
586
    (catch 'to-lisp
445
587
      (set-pathnames)
 
588
      (set-locale)
446
589
      (setf (values input-stream batch-flag) 
447
590
            (process-maxima-args input-stream batch-flag))
448
 
      #+(or cmu sbcl clisp allegro mcl)
449
591
      (progn
450
592
        (loop 
451
 
           (with-simple-restart (macsyma-quit "Macsyma top-level")
452
 
             (macsyma-top-level input-stream batch-flag))))
453
 
      #-(or cmu sbcl clisp allegro mcl)
454
 
      (catch 'macsyma-quit
455
 
        (macsyma-top-level input-stream batch-flag)))))
456
 
 
457
 
(import 'user::run)
458
 
 
459
 
($setup_autoload "eigen.mac" '$eigenvectors '$eigenvalues)
 
593
         (with-simple-restart (macsyma-quit "Maxima top-level")
 
594
             (macsyma-top-level input-stream batch-flag)))))))
 
595
 
 
596
(import 'cl-user::run)
460
597
 
461
598
(defun $to_lisp ()
462
 
  (format t "~&Type (to-maxima) to restart~%")
 
599
  (format t "~&Type (to-maxima) to restart, ($quit) to quit Maxima.~%")
463
600
  (let ((old-debugger-hook *debugger-hook*))
464
601
    (catch 'to-maxima
465
602
      (unwind-protect
466
 
          (maxima-read-eval-print-loop)
 
603
           (maxima-read-eval-print-loop)
467
604
        (setf *debugger-hook* old-debugger-hook)
468
605
        (format t "Returning to Maxima~%"))))
469
 
)
 
606
  )
470
607
 
471
608
(defun to-maxima ()
472
609
  (throw 'to-maxima t))
482
619
       (prin1 (eval form))))))
483
620
 
484
621
(defun maxima-lisp-debugger-repl (condition me-or-my-encapsulation)
 
622
  (declare (ignore me-or-my-encapsulation))
485
623
  (format t "~&Maxima encountered a Lisp error:~%~% ~A" condition)
486
624
  (format t "~&~%Automatically continuing.~%To reenable the Lisp debugger set *debugger-hook* to nil.~%")
487
625
  (throw 'to-maxima-repl t))
488
626
 
489
 
(defun $jfa_lisp ()
490
 
  (format t "jfa was here"))
491
 
 
492
 
(defvar $help "type describe(topic) or example(topic);")
493
 
 
494
 
(defun $help () $help)                  ;
495
 
 
496
 
;; CMUCL needs because when maxima reaches EOF, it calls BYE, not $QUIT.
497
 
#+cmu
498
 
(defun bye ()
499
 
  (ext:quit))
500
 
 
501
 
#+sbcl
502
 
(defun bye ()
503
 
  (sb-ext:quit))
504
 
 
505
 
#+clisp
506
 
(defun bye ()
507
 
  (ext:quit))
508
 
 
509
 
#+allegro
510
 
(defun bye ()
511
 
  (excl:exit))
512
 
 
513
 
#+mcl
514
 
(defun bye ()
515
 
  (ccl::quit))
516
 
 
517
 
(defun $maxima_server (port)
518
 
  (load "/home/amundson/devel/maxima/archive/src/server.lisp")
519
 
  (user::setup port))
 
627
(defvar $help "type `describe(topic);' or `example(topic);' or `? topic'")
 
628
 
 
629
(defun $help (&rest args)
 
630
  (declare (ignore args))
 
631
  $help)
 
632
 
 
633
;;; Now that all of maxima has been loaded, define the various lists
 
634
;;; and hashtables of builtin symbols and values.
 
635
 
 
636
;;; The symbols in problematic-symbols contains properties with
 
637
;;; circular data structures. Attempting to copy a circular structure
 
638
;;; into *builtin-symbol-props* would cause a hang. Lacking a better
 
639
;;; solution, we simply avoid those symbols.
 
640
(let ((problematic-symbols '($%gamma $%phi $global $%pi $%e)))
 
641
  (do-symbols (s (find-package :maxima))
 
642
    (when (and (eql (symbol-package s) (find-package :maxima))
 
643
               (memq (getchar s 1) '($ % &)))
 
644
      (push s *builtin-symbols*)
 
645
      (when (not (memq s problematic-symbols))
 
646
        (setf (gethash s *builtin-symbol-props*)
 
647
              (copy-tree (symbol-plist s)))))))
 
648
 
 
649
(dolist (s *builtin-symbols*)
 
650
  (when (boundp s)
 
651
    (push s *builtin-symbols-with-values*)))
 
652
 
 
653
(dolist (s *builtin-symbols-with-values*)
 
654
  (setf (gethash s *builtin-symbol-values*) (symbol-value s)))
 
655
 
 
656
(setf *builtin-$props* (copy-list $props))
 
657
(setf *builtin-$rules* (copy-list $rules))