1
0
forked from alex-eg/sex

index a unit past its first bad form

Record plain declarations, with location and docstring, and keep going
when one toplevel form is wrong. sexc --check and --symbols print
that. Specs, realizations, and closure helpers stay out of the index
for future rework (@alex-eg).
This commit is contained in:
2026-11-11 07:38:33 +03:00
parent 5e842c4df6
commit 7bbb8e19ac
10 changed files with 876 additions and 50 deletions

View File

@@ -21,7 +21,8 @@
load-persistent-module-paths
check-public-interface
module-dependencies
read-public-interface)
read-public-interface
reset-modules!)
(define +persistent-module-paths+ (list))
@@ -35,6 +36,14 @@
(define (mark-imported! path)
(set! +imported-modules+ (cons (normalize-pathname path) +imported-modules+)))
;;; Drop what the previous unit imported, read, and exported. The search
;;; path stays: it is the process's, not the unit's.
(define (reset-modules!)
(set! +imported-modules+ (list))
(set! +modules-read+ (list))
(set! +modules-expanded+ (list))
(set! +module-exports+ (list)))
(define (get-modules-public-forms import-form)
;; How Sex handles modules:
;; For each module IMPORT-FORM names, construct path, find module by