[racket] recognizing undefined; shared in TR

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Tue Sep 6 08:02:09 EDT 2011

That was my initial reaction, but on further inspection, I don't think
that "constant" or "value" are defined such that you can draw that
inference --- and I doubt that we want the terms to be defined that
way. For example, I think it's reasonable to write "the constant 3.14",
even though there's more than one 3.14 at the level of `eq?'.

At Tue, 6 Sep 2011 09:35:59 +0200, "Jos Koot" wrote:
> Your first pointer says:
> 'THE constant #<undefined> ...'
> Does the particle 'The' not imply that letrec always uses the same (eq?)
> constant for initialization?
> 
> -----Original Message-----
> From: users-bounces at racket-lang.org [mailto:users-bounces at racket-lang.org]
> On Behalf Of Danny Yoo
> Sent: lunes, 05 de septiembre de 2011 21:09
> To: Shriram Krishnamurthi
> Cc: users at racket-lang.org
> Subject: Re: [racket] recognizing undefined; shared in TR
> 
> On Mon, Sep 5, 2011 at 2:18 PM, Shriram Krishnamurthi <sk at cs.brown.edu>
> wrote:
> > On Sat, Sep 3, 2011 at 11:17 PM, Shriram Krishnamurthi <sk at cs.brown.edu>
> wrote:
> >> Is there a way of checking whether a value position is undefined?
> >> Specifically, I'm trying to recognize the undefined value put in
> >> structures by SHARED.  It appears that a undefined value is sometimes
> >> EQ? to another one, but this doesn't seem to be specified in the
> >> documentation (ie, that there is only one undefined value).
> >
> > Anyone have any thoughts on this?  Is it okay to use EQ?
> 
> According to:
> 
>     http://docs.racket-lang.org/reference/void.html
> 
> we know the value of undefined is a constant, but there's no guarantee
> that they're the same value.
> 
> 
> However, I'm certain that undefined is a singleton value, from the
> implementation details in:
> 
>  
> http://docs.racket-lang.org/inside/im_values_types.html#(idx._(gentag._143._
> (lib._scribblings/inside/inside..scrbl)))
> 
> _________________________________________________
>   For list-related administrative tasks:
>   http://lists.racket-lang.org/listinfo/users
> 
> 
> _________________________________________________
>   For list-related administrative tasks:
>   http://lists.racket-lang.org/listinfo/users



Posted on the users mailing list.