
#338: read-invoke #" reader-macro doesn't work for top level forms -------------------------+------------------------------------------------- Reporter: | Owner: Mark Evenson charmon | Type: defect | Status: closed Priority: major | Milestone: 1.9.1 Component: | Version: 1.3.0-dev libraries | Keywords: read-invoke sharpsign-doublequote Resolution: fixed | jss has-test Parent Tickets: | -------------------------+------------------------------------------------- Changes (by Mark Evenson): * status: assigned => closed * resolution: => fixed Old description:
Attempting to use the #" read-invoke reader macro fails for top-level forms:
;; This works: (defun bar () (#"openConnection" (jss::new 'java.net.url "http://google.com"))) (bar)
;; This doesn't: (#"openConnection" (jss::new 'java.net.url "http://google.com"))
And here is the stack trace:
The value (LAMBDA (#1=#:G5344 &REST #2=#:G5345) (JSS:INVOKE-RESTARGS "openConnection" #1# #2# NIL)) is not of type SYMBOL. [Condition of type TYPE-ERROR]
Restarts: 0: [ABORT] Abort compilation. 1: [*ABORT] Return to SLIME's top level. 2: [ABORT] Abort thread.
Backtrace: 0: (#<FUNCTION {4EF56F8}> #<TYPE-ERROR {5D0F047B}> #<FUNCTION {4EF56F8}>) 1: (APPLY #<FUNCTION {4EF56F8}> (#<TYPE-ERROR {5D0F047B}> #<FUNCTION {4EF56F8}>)) 2: (SYSTEM::RUN-HOOK SYSTEM::*INVOKE-DEBUGGER-HOOK* #<TYPE-ERROR {5D0F047B}> #<FUNCTION {4EF56F8}>) 3: (INVOKE-DEBUGGER #<TYPE-ERROR {5D0F047B}>) 4: org.armedbear.lisp.Lisp.error(Lisp.java:382) 5: org.armedbear.lisp.Lisp.type_error(Lisp.java:435) 6: org.armedbear.lisp.Lisp.checkSymbol(Lisp.java:1089) 7: org.armedbear.lisp.Lisp.get(Lisp.java:1962) 8: org.armedbear.lisp.compile_file_50.execute(compile-file.lisp:606) ...
New description: c.f. <https://github.com/armedbear/abcl/issues/541> Attempting to use the #" read-invoke reader macro fails for top-level forms: ;; This works: (defun bar () (#"openConnection" (jss::new 'java.net.url "http://google.com"))) (bar) ;; This doesn't: (#"openConnection" (jss::new 'java.net.url "http://google.com")) And here is the stack trace: The value (LAMBDA (#1=#:G5344 &REST #2=#:G5345) (JSS:INVOKE-RESTARGS "openConnection" #1# #2# NIL)) is not of type SYMBOL. [Condition of type TYPE-ERROR] Restarts: 0: [ABORT] Abort compilation. 1: [*ABORT] Return to SLIME's top level. 2: [ABORT] Abort thread. Backtrace: 0: (#<FUNCTION {4EF56F8}> #<TYPE-ERROR {5D0F047B}> #<FUNCTION {4EF56F8}>) 1: (APPLY #<FUNCTION {4EF56F8}> (#<TYPE-ERROR {5D0F047B}> #<FUNCTION {4EF56F8}>)) 2: (SYSTEM::RUN-HOOK SYSTEM::*INVOKE-DEBUGGER-HOOK* #<TYPE-ERROR {5D0F047B}> #<FUNCTION {4EF56F8}>) 3: (INVOKE-DEBUGGER #<TYPE-ERROR {5D0F047B}>) 4: org.armedbear.lisp.Lisp.error(Lisp.java:382) 5: org.armedbear.lisp.Lisp.type_error(Lisp.java:435) 6: org.armedbear.lisp.Lisp.checkSymbol(Lisp.java:1089) 7: org.armedbear.lisp.Lisp.get(Lisp.java:1962) 8: org.armedbear.lisp.compile_file_50.execute(compile-file.lisp:606) ... -- Comment: Fixed with <https://abcl.org/trac/changeset/15630>. c.f. <https://github.com/armedbear/abcl/pull/545> Thanks to Alejandro Zamora Fonseca <https://github.com/alejandrozf> -- Ticket URL: <https://abcl.org/trac/ticket/338#comment:16> armedbear <https://abcl.org> armedbear