Re: [Audacity-nyquist] *scratch* property values not protected from deletion?
A free multi-track audio editor and recorder
Brought to you by:
aosiniao
From: edgar <edg...@we...> - 2009-11-28 13:08:14
|
Roger wrote: > Symbols are never garbage collected, so you do not need to set them > to non-nil values to keep them around. > > The main problem is that when you write: > > (setf *scratch* nil) > (putprop *scratch* ...) > > *scratch* is evaluated as an argument, so if the value is NIL, you > are passing NIL to putprol. NIL is not a symbol, so it cannot have > a property list. Thanks, thats right, definetly my fault. As it turns out, by quoting *scratch* I do NOT need to set *scratch* to any variable or function value before using PUTPROP. After a fresh start of Audacity (to make sure no values are bound to *scratch*), even with in-between GC runs it works: (putprop '*scratch* 'value 'property) (gc) (format t "~a~%" (get '*scratch* 'property)) prints: VALUE Okay, the GC test is a bit over-paranoid, but it's always better to go for sure (says the repair-man edgar) ... Thanks again, - edgar -- The author of this email does not necessarily endorse the following advertisements, which are the sole responsibility of the advertiser: |