[racket-dev] [plt] Push #23424: master branch updated

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Sat Sep 3 17:37:36 EDT 2011

At Sat, 3 Sep 2011 17:25:58 -0400, Sam Tobin-Hochstadt wrote:
> On Thu, Sep 1, 2011 at 5:20 PM,  <tewk at racket-lang.org> wrote:
> >
> > src/racket/src/place.c
> > ~~~~~~~~~~~~~~~~~~~~~~
> > + REGISTER_SO(quote_symbol);
> > + quote_symbol = scheme_intern_symbol("quote");
> 
> This is the third definition of 'quote_symbol' in the source.  Are
> repeated definitions a problem? 

It doesn't seem like a problem to me. What did you have in mind?

This isn't some constant that we might change. It's more like writing

 (define FIVE 5)

except that it's so difficult to write the `quote' symbol in C that we
really end up writing the equivalent of

 (define QUOTE 'quote)

sometimes.

> Can these be shared (other than via
> the intern table)?

A `scheme_quote_symbol' could be defined somewhere and exported to the
other places. The tradeoff is writing `(define QUOTE 'quote)' multiple
times versus making a global change.



Posted on the dev mailing list.