Hi Vladimir,<div><br></div><div>Thanks for the report! I've committed the fix to trunk, which means it's up for inclusion in 1.1.0 which is due later this year.</div><div><br></div><div>Bye,</div><div><br></div><div>
Erik.<br><br><div class="gmail_quote">On Mon, Aug 6, 2012 at 4:02 AM, Vladimir Sedach <span dir="ltr"><<a href="mailto:vsedach@gmail.com" target="_blank">vsedach@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
<br>
Currently, ABCL doesn't qualify the package of FIND-PACKAGE when it<br>
serializes a package in a compiled file. This causes a bug when<br>
loading a compiled file that has code (for example, the EOS:TEST macro<br>
from the EOS unit-testing library) that serializes a package, and<br>
occurs after an IN-PACKAGE into a package that either shadows or does<br>
not import FIND-PACKAGE from COMMON-LISP.<br>
<br>
I didn't work out a minimum test case, but the problem can be observed<br>
when trying to load the Parenscript test suite:<br>
(ql:quickload :parenscript.test)<br>
<br>
Here's the fix:<br>
<br>
Index: src/org/armedbear/lisp/compiler-pass2.lisp<br>
===================================================================<br>
--- src/org/armedbear/lisp/compiler-pass2.lisp (revision 14055)<br>
+++ src/org/armedbear/lisp/compiler-pass2.lisp (working copy)<br>
@@ -1191,7 +1191,7 @@<br>
<br>
(defun serialize-package (pkg)<br>
"Generate code to restore a serialized package."<br>
- (emit 'ldc (pool-string (concatenate 'string "#.(FIND-PACKAGE \""<br>
+ (emit 'ldc (pool-string (concatenate 'string "#.(CL:FIND-PACKAGE \""<br>
(package-name pkg) "\")")))<br>
(emit-invokestatic +lisp+ "readObjectFromString"<br>
(list +java-string+) +lisp-object+))<br>
Index: src/org/armedbear/lisp/Package.java<br>
===================================================================<br>
--- src/org/armedbear/lisp/Package.java (revision 14055)<br>
+++ src/org/armedbear/lisp/Package.java (working copy)<br>
@@ -865,7 +865,7 @@<br>
public String printObject()<br>
{<br>
if (_PRINT_FASL_.symbolValue() != NIL && name != null) {<br>
- StringBuilder sb = new StringBuilder("#.(FIND-PACKAGE \"");<br>
+ StringBuilder sb = new StringBuilder("#.(CL:FIND-PACKAGE \"");<br>
sb.append(name);<br>
sb.append("\")");<br>
return sb.toString();<br>
<br>
Happy hacking,<br>
Vladimir<br>
<br>
_______________________________________________<br>
armedbear-devel mailing list<br>
<a href="mailto:armedbear-devel@common-lisp.net">armedbear-devel@common-lisp.net</a><br>
<a href="http://lists.common-lisp.net/cgi-bin/mailman/listinfo/armedbear-devel" target="_blank">http://lists.common-lisp.net/cgi-bin/mailman/listinfo/armedbear-devel</a><br>
</blockquote></div><br></div>