[Grace-core] Singleton types

Michael Homer mwh at ecs.vuw.ac.nz
Sun Sep 2 17:12:25 PDT 2012


On Mon, Sep 3, 2012 at 7:47 AM, James Noble <kjx at ecs.vuw.ac.nz> wrote:
>> The Grace spec in section 11.10 specifies that any object may be used as the name of a singleton type without further annotation.  In the first draft of the SIGCSE paper I had written that for object obj as "obj.type" rather than just "obj".  Is the spec the agreed on notation?  If so, I'll change the paper.
>
> I think  that works for any "autozygotic" object.   Otherwise I think it needs to be something like "singleton(e)"
> this is related to pattern matching, because types are patterns.  Michael?
Numbers and strings could be special-cased, I guess, but it can't
apply to "any" autozygotic object unless you want to go far down that
hole.

I think singleton(e) was the syntax in use as well. There will
probably need to be some restrictions on what e can be to make it
practical, but those can be glossed over.
-Michael


More information about the Grace-core mailing list