Opened 11 years ago
Closed 10 years ago
#516 closed defect (fixed)
send/stret macro produces Error: unknown arg spec :REGISTERS
Reported by: | rongarret | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | Objective-C Bridge | Version: | trunk |
Keywords: | Cc: |
Description
With e bound to e.g. an event object, I get the following error: ? (ccl::slet ((l (send e 'location-In-Window)))) ;Compiler warnings : ; In an anonymous lambda form: Undeclared free variable E > Error: unknown arg spec :REGISTERS > While executing: %FF-CALL, in process Listener(7). The form eventually macroexpands (through an amazingly byzantine process) into something containing: (%FF-CALL (%REFERENCE-EXTERNAL-ENTRY-POINT (LOAD-TIME-VALUE (EXTERNAL "_objc_msgSend"))) :REGISTERS #:G37 :ADDRESS E :ADDRESS (OBJC:@SELECTOR "locationInWindow") :VOID) which %FF-CALL doesn't seem to know what to do with.
Change History (3)
comment:1 Changed 11 years ago by rme
comment:2 Changed 11 years ago by gb
An explanation for why the error is happening (there's a deeper problem, but this is the short version) is that something's causing the trunk IDE to start out with:
? (ccl:declaration-information 'optimize nil) ((SPEED 0) (SAFETY 3) (COMPILATION-SPEED 0) (SPACE 0) (DEBUG 3))
in effect.
That discourages the compiler from inlining the call to %FF-CALL (and from doing lots of other things), and exposes the fact that the %FF-CALL function doesn't understand what :registers is all about.
comment:3 Changed 10 years ago by rme
- Resolution set to fixed
- Status changed from new to closed
r12241 should fix this
Note: See
TracTickets for help on using
tickets.
I would recommend that you don't use SEND, which is basically obsolete. (Yes, the Objective-C bridge chapter in the manual is horribly out-of-date.)