[Ecls-list] Special symbols that might benefit from implicit locking or thread-local bindings

Juan Jose Garcia-Ripoll juanjose.garciaripoll at googlemail.com
Mon Aug 1 12:05:39 UTC 2011

On Mon, Aug 1, 2011 at 11:43 AM, Matthew Mondor <mm_lists at pulsar-zone.net>wrote:

> So I guess the symbols to rebind would be only the ones which are
> likely to be SETQ/SETF via common standard functions rather than via
> LET, such as indeed *PACKAGE* (WITH-PACKAGE would not have needed such,
> but IN-PACKAGE does)...

Even *PACKAGE* might not need to be thread-local. The place where *package*
is most used is in loaded code, within IN-PACKAGE statements, but LOAD binds
*PACKAGE*, both in binary and in source files, so it automatically becomes
thread-local. User code should also bind *PACKAGE*, both when reading and
when printing, because otherwise the code may suddenly break when used in
the wrong context... So maybe after all there are not that many special
variables that need protection if one restricts to LET-bindings instead of
just SETF.


Instituto de Física Fundamental, CSIC
c/ Serrano, 113b, Madrid 28006 (Spain)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/ecl-devel/attachments/20110801/f2bdfb6d/attachment.html>

More information about the ecl-devel mailing list