diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2022-03-31 01:16:29 -0700 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2022-03-31 01:16:29 -0700 |
commit | 4700005a4302a1eed2d9e5bc7f1668b2621ff1f0 (patch) | |
tree | 47bc0dc2427edd1a439775f14058861bb3d08553 /stdlib/compiler.tl | |
parent | 0c49e3197f5713c72f2d088a4c9f382f6c019ad2 (diff) | |
download | txr-4700005a4302a1eed2d9e5bc7f1668b2621ff1f0.tar.gz txr-4700005a4302a1eed2d9e5bc7f1668b2621ff1f0.tar.bz2 txr-4700005a4302a1eed2d9e5bc7f1668b2621ff1f0.zip |
compiler: package-manipulating top-level forms bug.
* stdlib/compiler.tl (compile-file-conditionally): Recognize a
potential package-manipulating form not checking whether its
main operator is in %pakage-manip% list, but whether any
global functions that its compiled image references are in
that list. This is the same approach that is used in
dump-compiled-objects. This fix is needed for correctly
recognizing defpackage as a package-manipulating form.
defpackage macro-expands to a let form which contains a call
to make-package. Testing whether let is in %package-manip% is
useless; of course it isn't, and the test overlooks
make-package.
Diffstat (limited to 'stdlib/compiler.tl')
-rw-r--r-- | stdlib/compiler.tl | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/stdlib/compiler.tl b/stdlib/compiler.tl index 63ceb519..585712f9 100644 --- a/stdlib/compiler.tl +++ b/stdlib/compiler.tl @@ -2361,7 +2361,8 @@ (not (constantp form))) (let* ((vm-desc (compile-toplevel form)) (flat-vd (list-from-vm-desc vm-desc)) - (fence (member sym %package-manip%))) + (symvec (sys:vm-desc-symvec vm-desc)) + (fence (isecp symvec %package-manip%))) (when *eval* (let ((pa *package-alist*)) (sys:vm-execute-toplevel vm-desc) |