[Openmcl-devel] ns:ns-tracking-area not present in 32bit CCL

Gary Byers gb at clozure.com
Tue Jun 9 13:17:41 UTC 2009


The code that sets the optimization settings (persistently and probably
not intentionally so) is in ccl/examples/cocoa/easygui/views.lisp.  For
reasons that I don't pretend to understand, that file is loaded everytime
that the standalone IDE starts up, but isn't loaded or referenced when
one just does (require "COCOA").

That's my best guess; if it's not correct and it was more important
that I can imagine it to be to determine what other difference in
environment led to to different behavior, then I suppose that - armed
with knowledge of what all of those differences are - one could come
up with a more accurate explanation.

I don't know.  To be honest, I don't really care; it seems like the
time spent puzzling over this could be better spent trying to fix the bug.

On Tue, 9 Jun 2009, Ron Garret wrote:

> Why is Rainer seeing this bug now and not me?  At this point we're running 
> the same code on the same CCL version on the same OS X version.
>
> rg
>
> On Jun 9, 2009, at 4:32 AM, Gary Byers wrote:
>
>> The bug's somewhat tersesly described in:
>> 
>> <http://trac.clozure.com/openmcl/ticket/516>
>> 
>> It's still open, though the code in the trunk version of the IDE
>> that was exposing/triggering the problem has been changed.
>> 
>> That code can cause the IDE to start up with
>> 
>> ;;;; see CLtL2; DECLARATION-INFORMATION didn't make it into ANSI CL
>> ? (ccl:declaration-information 'optimize nil)
>> ((SPEED 0) (SAFETY 3) (COMPILATION-SPEED 0) (SPACE 0) (DEBUG 3))
>> 
>> This combination of OPTIMIZE settings causes some rarely-executed
>> code to be executed, and the real bug is in that code.
>> (Of course, this should just have the effect of making the code as
>> slow, bloated, and stupid as possible, but it incidentally exposes
>> a bug.)
>> 
>> Untile the real bug is if fixed, you can work around the problem by doing:
>> 
>> ? (declaim (optimize (speed 1) (space 1) (safety 1) (debug 1) 
>> (compilation-speed 1)))
>> 
>> on startup.
>> 
>> 
>> 
>> 
>> On Tue, 9 Jun 2009, Rainer Joswig wrote:
>> 
>>> Same error in  Clozure Common Lisp Version 1.3-r12235M  (DarwinX8664).
>>> 
>>> Mac OS X 10.5.7 on 64bit Intel...
>>> 
>>> 
>>> *** Error in event process: unknown arg spec :REGISTERS
>>> 
>>> (442BE8) : 0 (FUNCALL #'#<(:INTERNAL |-[StandardView drawRect:]|)>
>>> #<SIMPLE-ERROR #x3000421B439D>) 85
>>> (#:G2965)
>>>  #:G2965: #<SIMPLE-ERROR #x3000421B439D>
>>> 
>>> #:COMPILER-VAR: (NIL)
>>> #:G2962: #<A Foreign Pointer #x7FFF5FBFD360>
>>> 
>>> (442C10) : 1 (SIGNAL #<SIMPLE-ERROR #x3000421B439D>) 981
>>> (CONDITION &REST CCL::ARGS)
>>>  CONDITION: #<SIMPLE-ERROR #x3000421B439D>
>>>  CCL::ARGS: NIL
>>> 
>>> CCL::%HANDLERS%: ((ERROR) (ERROR))
>>> CCL::TAG: #<SIMPLE-ERROR #x3000421B439D>
>>> CCL::HANDLERS: CCL::*BACKTRACE-CONTEXTS*
>>> CCL::FN: #<COMPILED-LEXICAL-CLOSURE (:INTERNAL |-[StandardView
>>> drawRect:]|) #x493DBF>
>>> 
>>> (442C68) : 2 (%ERROR #<SIMPLE-ERROR #x3000421B439D> (:REGISTERS)
>>> 558482) 117
>>> (CONDITION CCL::ARGS CCL::ERROR-POINTER)
>>>  CONDITION: #<SIMPLE-ERROR #x3000421B439D>
>>>  CCL::ARGS: (:REGISTERS)
>>>  CCL::ERROR-POINTER: 558482
>>> 
>>> ...
>>> 
>>> Regards,
>>> 
>>> Rainer Joswig
>>> 
>>> 
>>> 
>>> Am 09.06.2009 um 07:02 schrieb Ron Garret:
>>> 
>>>> Try updating.  The 1.3 branch is currently at verison r12153M.  It
>>>> works for me on that version.
>>>> 
>>>> rg
>>>> 
>>>> On Jun 8, 2009, at 9:35 PM, Rainer Joswig wrote:
>>>> 
>>>>> 
>>>>> 
>>>>> using Clozure Common Lisp Version 1.3-r12088M  (DarwinX8664)
>>>>> 
>>>>> 
>>>>> On executing the add-subview example form in draggable.lisp
>>>>> 
>>>>> I get:
>>>>> 
>>>>> *** Error in event process: unknown arg spec :REGISTERS
>>>>> 
>>>>> (442BE8) : 0 (FUNCALL #'#<(:INTERNAL |-[StandardView drawRect:]|)>
>>>>> #<SIMPLE-ERROR #x3000420F8DBD>) 85
>>>>> (#:G5085)
>>>>> #:G5085: #<SIMPLE-ERROR #x3000420F8DBD>
>>>>> 
>>>>> #:COMPILER-VAR: (NIL)
>>>>> #:G5082: #<A Foreign Pointer #x7FFF5FBFD360>
>>>>> 
>>>>> (442C10) : 1 (SIGNAL #<SIMPLE-ERROR #x3000420F8DBD>) 981
>>>>> (CONDITION &REST CCL::ARGS)
>>>>> CONDITION: #<SIMPLE-ERROR #x3000420F8DBD>
>>>>> CCL::ARGS: NIL
>>>>> 
>>>>> CCL::%HANDLERS%: ((ERROR) (ERROR))
>>>>> CCL::TAG: #<SIMPLE-ERROR #x3000420F8DBD>
>>>>> CCL::HANDLERS: CCL::*BACKTRACE-CONTEXTS*
>>>>> CCL::FN: #<COMPILED-LEXICAL-CLOSURE (:INTERNAL |-[StandardView
>>>>> drawRect:]|) #x493DBF>
>>>>> 
>>>>> (442C68) : 2 (%ERROR #<SIMPLE-ERROR #x3000420F8DBD> (:REGISTERS)
>>>>> 558482) 117
>>>>> (CONDITION CCL::ARGS CCL::ERROR-POINTER)
>>>>> CONDITION: #<SIMPLE-ERROR #x3000420F8DBD>
>>>>> CCL::ARGS: (:REGISTERS)
>>>>> CCL::ERROR-POINTER: 558482
>>>>> 
>>>>> 
>>>>> 
>>>>> (442C90) : 3 (%FF-CALL 140735390423728 :REGISTERS #<NS-OBJECT
>>>>> <NSCFType: 0x170192c0> (#x170192C0)> :ADDRESS #<NS-CONSTANT-STRING
>>>>> "Lisp Rules!" (#x137CD2F0)> :ADDRESS #<A Foreign Pointer
>>>>> #x7FFF82F59600> :ADDRESS #<NS-MUTABLE-DICTIONARY {
>>>>> NSFont = "TimesNewRomanPS-ItalicMT 48.00 pt. P [] (0x13799150)
>>>>> fobj=0x170178c0, spc=12.00";
>>>>> } (#x17019E50)> :VOID) 701
>>>>> (CCL::ENTRY &REST CCL::SPECS-AND-VALS)
>>>>> CCL::ENTRY: 140735390423728
>>>>> CCL::SPECS-AND-VALS: (:REGISTERS #<NS-OBJECT <NSCFType:
>>>>> 0x170192c0> (#x170192C0)> :ADDRESS #<NS-CONSTANT-STRING "Lisp
>>>>> Rules!" (#x137CD2F0)> :ADDRESS ...)
>>>>> 
>>>>> CCL::LEN: 9
>>>>> CCL::TOTAL-WORDS: 0
>>>>> CCL::RESULT-SPEC: :VOID
>>>>> CCL::NARGS: 4
>>>>> CCL::N-FP-ARGS: 0
>>>>> CCL::I: 0
>>>>> CCL::SPECS: (:REGISTERS #<NS-OBJECT <NSCFType: 0x170192c0>
>>>>> (#x170192C0)> :ADDRESS #<NS-CONSTANT-STRING "Lisp
>>>>> Rules!" (#x137CD2F0)> :ADDRESS ...)
>>>>> CCL::SPEC: :REGISTERS
>>>>> 
>>>>> (442CF8) : 4 (FUNCALL #'#<Anonymous Function #x300041D9AB4F> #<NS-
>>>>> CONSTANT-STRING "Lisp Rules!" (#x137CD2F0)> #S(CCL::OBJC-
>>>>> SELECTOR :NAME "sizeWithAttributes:" :%SEL #<A Foreign Pointer
>>>>> #x7FFF82F59600>) #<NS-MUTABLE-DICTIONARY {
>>>>> NSFont = "TimesNewRomanPS-ItalicMT 48.00 pt. P [] (0x13799150)
>>>>> fobj=0x170178c0, spc=12.00";
>>>>> } (#x17019E50)>) 805
>>>>> (#:G3751 #:G3752 CCL::ARG0)
>>>>> #:G3751: #<NS-CONSTANT-STRING "Lisp Rules!" (#x137CD2F0)>
>>>>> #:G3752: #S(CCL::OBJC-SELECTOR :NAME "sizeWithAttributes:" :%SEL
>>>>> #<A Foreign Pointer #x7FFF82F59600>)
>>>>> CCL::ARG0: #<NS-MUTABLE-DICTIONARY {
>>>>> NSFont = "TimesNewRomanPS-ItalicMT 48.00 pt. P [] (0x13799150)
>>>>> fobj=0x170178c0, spc=12.00";
>>>>> } (#x17019E50)>
>>>>> 
>>>>> #:G3753: #<NS-SIZE 0 X 0 #x3000420F8EDD> [gcable] (#x17029190)
>>>>> #:G3756: #<A Foreign Pointer #x17029190>
>>>>> #:G3755: #<NS-OBJECT <NSCFType: 0x170192c0> (#x170192C0)>
>>>>> 
>>>>> (442D38) : 5 (FUNCALL #'#<(:INTERNAL CCL::SEND-UNAMBIGUOUS-MESSAGE
>>>>> (SHARED-INITIALIZE :AFTER (CCL::OBJC-DISPATCH-FUNCTION T)))> #<NS-
>>>>> CONSTANT-STRING "Lisp Rules!" (#x137CD2F0)> #<NS-MUTABLE-DICTIONARY {
>>>>> NSFont = "TimesNewRomanPS-ItalicMT 48.00 pt. P [] (0x13799150)
>>>>> fobj=0x170178c0, spc=12.00";
>>>>> } (#x17019E50)>) 501
>>>>> (CCL::RECEIVER &REST CCL::ARGS)
>>>>> CCL::RECEIVER: #<NS-CONSTANT-STRING "Lisp Rules!" (#x137CD2F0)>
>>>>> CCL::ARGS: (#<NS-MUTABLE-DICTIONARY {
>>>>> NSFont = "TimesNewRomanPS-ItalicMT 48.00 pt. P [] (0x13799150)
>>>>> fobj=0x170178c0, spc=12.00";
>>>>> } (#x17019E50)>)
>>>>> 
>>>>> CCL::SELECTOR: #S(CCL::OBJC-SELECTOR :NAME "sizeWithAttributes:" :
>>>>> %SEL #<A Foreign Pointer #x7FFF82F59600>)
>>>>> FUNCTION: #<Anonymous Function #x300041D9AB4F>
>>>>> 
>>>>> (442D78) : 6 (FUNCALL #'#<#<STANDARD-METHOD VIEW-DRAW-CONTENTS
>>>>> (TEXT-VIEW)>> #<TESTVIEW #x30004201D12D> #<NS-RECT 100 X 100 @ 0,0
>>>>> (#x7FFF5FBFD370) #x3000420F928D>) 229
>>>>> (V &OPTIONAL RECT)
>>>>> V: #<TESTVIEW #x30004201D12D>
>>>>> RECT: #<NS-RECT 100 X 100 @ 0,0 (#x7FFF5FBFD370) #x3000420F928D>
>>>>> 
>>>>> 
>>>>> 
>>>>> (442DA0) : 7 (FUNCALL #'#<|-[StandardView drawRect:]|>
>>>>> 17591849974380) 981
>>>>> (#:G5081)
>>>>> #:G5081: 17591849974380
>>>>> 
>>>>> #:G5088: #<A Foreign Pointer #x7FFF5FBFD360>
>>>>> #:G5082: #<A Foreign Pointer #x7FFF5FBFD360>
>>>>> #:COMPILER-VAR: (NIL)
>>>>> #:G5087: #<COMPILED-LEXICAL-CLOSURE (:INTERNAL |-[StandardView
>>>>> drawRect:]|) #x493DBF>
>>>>> #:G5089: (CONDITION #<COMPILED-LEXICAL-CLOSURE # #x493DBF>)
>>>>> CCL::%HANDLERS%: ((CONDITION #) (ERROR))
>>>>> SELF: #<STANDARD-VIEW <StandardView: 0x170221c0> (#x170221C0)>
>>>>> _CMD: #<A Foreign Pointer #x7FFF83013F38>
>>>>> RECT: #<NS-RECT 100 X 100 @ 0,0 (#x7FFF5FBFD370) #x3000420F928D>
>>>>> 
>>>>> (442E48) : 8 (%PASCAL-FUNCTIONS% 277 17591849974380) 397
>>>>> (CCL::INDEX CCL::ARGS-PTR-FIXNUM)
>>>>> CCL::INDEX: 277
>>>>> CCL::ARGS-PTR-FIXNUM: 17591849974380
>>>>> 
>>>>> CCL::LISP-FUNCTION: #<Compiled-function |-[StandardView drawRect:]|
>>>>> (Non-Global)  #x300041F007BF>
>>>>> WITHOUT-INTERRUPTS: NIL
>>>>> CCL::*CALLBACK-TRACE-P*: NIL
>>>>> 
>>>>> (442F08) : 10 (FUNCALL #'#<Anonymous Function #x30004122027F>
>>>>> #<LISP-APPLICATION <LispApplication: 0x1c3580> (#x1C3580)>
>>>>> #S(CCL::OBJC-SELECTOR :NAME "run" :%SEL #<A Foreign Pointer
>>>>> #x7FFF82FFFD68>)) 205
>>>>> (#:G3072 #:G3073)
>>>>> #:G3072: #<LISP-APPLICATION <LispApplication: 0x1c3580> (#x1C3580)>
>>>>> #:G3073: #S(CCL::OBJC-SELECTOR :NAME "run" :%SEL #<A Foreign
>>>>> Pointer #x7FFF82FFFD68>)
>>>>> 
>>>>> 
>>>>> 
>>>>> (442F28) : 11 (FUNCALL #'#<(:INTERNAL CCL::SEND-UNAMBIGUOUS-MESSAGE
>>>>> (SHARED-INITIALIZE :AFTER (CCL::OBJC-DISPATCH-FUNCTION T)))> #<LISP-
>>>>> APPLICATION <LispApplication: 0x1c3580> (#x1C3580)>) 501
>>>>> (CCL::RECEIVER &REST CCL::ARGS)
>>>>> CCL::RECEIVER: #<LISP-APPLICATION <LispApplication: 0x1c3580>
>>>>> (#x1C3580)>
>>>>> CCL::ARGS: NIL
>>>>> 
>>>>> CCL::SELECTOR: #S(CCL::OBJC-SELECTOR :NAME "run" :%SEL #<A Foreign
>>>>> Pointer #x7FFF82FFFD68>)
>>>>> FUNCTION: #<Anonymous Function #x30004122027F>
>>>>> 
>>>>> (442F68) : 12 (EVENT-LOOP NIL) 413
>>>>> (&OPTIONAL GUI::END-TEST)
>>>>> GUI::END-TEST: NIL
>>>>> 
>>>>> GUI::APP: #<LISP-APPLICATION <LispApplication: 0x1c3580> (#x1C3580)>
>>>>> *BREAK-ON-ERRORS*: NIL
>>>>> #:G163537: (ERROR)
>>>>> CCL::%HANDLERS%: ((ERROR))
>>>>> GUI::*EVENT-PROCESS-REPORTED-CONDITIONS*: (#<SIMPLE-ERROR
>>>>> #x3000420F8DBD>)
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> 
>>>>> Am 09.06.2009 um 02:44 schrieb Ron Garret:
>>>>> 
>>>>>> [This may be a repeat, but the original never showed up in my
>>>>>> inbox.  Also, there's an update at the end.]
>>>>>> 
>>>>>> On Jun 8, 2009, at 11:32 AM, Arthur W Cater wrote:
>>>>>> 
>>>>>>> Use #/addTrackingRect:owner:userData:assumeInside: with
>>>>>>> - the view
>>>>>>> - its #/bounds
>>>>>>> - a ns-object as target
>>>>>>> - ccl::+null-ptr+
>>>>>>> - #$NO
>>>>>>> 
>>>>>>> Then
>>>>>>> (objc:define-objc-method ((:void :mouse-entered (:id event))
>>>>>>> <theTargetClassYouUsed>) ...)
>>>>>>> 
>>>>>>> likewise :mouse-exited and :mouse-move
>>>>>> 
>>>>>> Thanks!  Updated version enclosed. This has been tested in 32-bit
>>>>>> CCL, and should now work on Tiger as well.
>>>>>> 
>>>>>> This version also fixes a bug whereby testviews did not get
>>>>>> properly re-initialized to add a tracker when the class got
>>>>>> redefined.  I was using an initialize-instance :after method when
>>>>>> I should have been using shared initialize -- I think.  There is
>>>>>> still a subtle bug which I can't figure out.  When you add a
>>>>>> highlighted mixin to an existing testview instance, you have to
>>>>>> click on it once before it starts to highlight itself.  I have no
>>>>>> idea why this is happening.  I may not be using shared-initialize
>>>>>> properly.  Maybe a CLOS wizard can help with some advice on the
>>>>>> proper way to do this.
>>>>>> 
>>>>>> UPDATE: it turns out that the reason for this is that calling
>>>>>> shared-initialize is done lazily.  So until there is an
>>>>>> interaction with the updated object it doesn't get re-initialized,
>>>>>> so add-tracker doesn't get called, so the event that would
>>>>>> normally cause the interaction never gets received.  Makes an
>>>>>> interesting little puzzle.
>>>>>> 
>>>>>> rg
>>>>>> 
>>>>>> <draggable.lisp>
>>>>>> _______________________________________________
>>>>>> Openmcl-devel mailing list
>>>>>> Openmcl-devel at clozure.com
>>>>>> http://clozure.com/mailman/listinfo/openmcl-devel
>>>>> 
>>>>> Rainer Joswig, Hamburg, Germany
>>>>> http://lispm.dyndns.org/
>>>>> mailto:joswig at lisp.de
>>>>> 
>>>>> 
>>> 
>>> Rainer Joswig, Hamburg, Germany
>>> http://lispm.dyndns.org/
>>> mailto:joswig at lisp.de
>>> 
>>> 
>>> 
>>> _______________________________________________
>>> Openmcl-devel mailing list
>>> Openmcl-devel at clozure.com
>>> http://clozure.com/mailman/listinfo/openmcl-devel
>>> 
>>> 
>> _______________________________________________
>> Openmcl-devel mailing list
>> Openmcl-devel at clozure.com
>> http://clozure.com/mailman/listinfo/openmcl-devel
>



More information about the Openmcl-devel mailing list