Changeset 8890


Ignore:
Timestamp:
Mar 26, 2008, 10:46:42 AM (11 years ago)
Author:
gb
Message:

Pull the boootstrapping/level-0 stuff off of plists, so that level-0
definitions have source info again.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/working-0711/ccl/lib/source-files.lisp

    r8884 r8890  
    1717;;;; RECORD-SOURCE-FILE and FIND-DEFINITIONS-FOR-NAME allow us to map names to source-notes.
    1818
    19 ;;;; A source-note is a ccl::source-note object, depeding on how much information we have available
     19;;;; A source-note is a ccl::source-note object, depending on how much information we have available
    2020;;;; at load time the source-note may be a complete source-note or it may just have the file-name.
    2121
     
    476476;;;; * Done loading the r-s-f stuff. Do some housekeeping.
    477477
     478;;; xload-level-0 has stored source file info on the plists of symbols
     479;;; that have definitions in level-0;**;*.lisp, under the indicator
     480;;; BOOTSRAPPING-SOURCE-FILES.  Remove those plist entries, and
     481;;; add equivalent info to *early-source-files*.
     482(let* ((path-notes ()))
     483  (flet ((find-source-note (path)
     484           (dolist (note path-notes
     485                    (let* ((new (%make-source-note :file-name path)))
     486                      (push new path-notes)
     487                      new))
     488             (when (eq (source-note-file-name note) path)
     489               (return note)))))
     490    (do-all-symbols (s)
     491      (let* ((info (get s 'bootstrapping-source-files)))
     492        (when info
     493          (remprop s 'bootstrapping-source-files)
     494          (when (atom info) (setq info `((function . ,info))))
     495          (dolist (pair info)
     496          (let* ((indicator (car pair))
     497                 (path (cdr pair))
     498                 (note (find-source-note path)))
     499            (push (list indicator s note) *early-source-files*))))))))
     500
     501       
     502     
     503   
     504
     505
    478506;; Now that the real r-s-f framework is ready we can go back and fixup the early stuff. This early
    479507;; stuff is everything that we wanted to register before having defined the registration/recording
     
    486514  do (real-register-definition-type type-name))
    487515
     516
    488517(loop
    489518  while *early-source-files*
Note: See TracChangeset for help on using the changeset viewer.