comp.lang.ada
 help / color / mirror / Atom feed
From: Eric Hughes <eric.eh9@gmail.com>
Subject: Re: User-defined type attributes
Date: Thu, 13 Mar 2008 20:55:27 -0700 (PDT)
Date: 2008-03-13T20:55:27-07:00	[thread overview]
Message-ID: <fa6b81ca-4cbd-4a14-af77-cc1d4c95b204@i29g2000prf.googlegroups.com> (raw)
In-Reply-To: 965suhjl0bxt$.74se2ylyksin.dlg@40tude.net

On Mar 13, 1:58 pm, "Dmitry A. Kazakov" <mail...@dmitry-kazakov.de>
wrote:
> In which sense function is static? If understand what you wrote, it simply
> means that the name "Callable" is static.

That's not what I meant.  Here's some sample notation, whose syntax is
merely illustrative.

    -- Declaration of an attribute
    generic
        task type T ;
    function T'Callable return boolean ;

    -- Declaration of a (static) implementation function
    generic
        task type T ;
    function Callable_Impl return access function( X : T ) return
boolean is static ;

    -- Binding of an implementation to an attribute
    generic
        task type T ;
        Obj : T ;
    for Obj'Callable use Callable_Impl.all( X => Obj ) ;

Regardless of whatever syntax is appropriate, one of the things that
makes me uncomfortable about attributes is that their definitions
don't have the same rigor of notation in their definitions as, say,
the standard libraries do.  In the spirit of separation compilation,
I'd like to see attribute definitions in specification packages, even
if their bodies exist solely within a compiler's implementation.


I wrote:
> Functions on a type are part of the tradition algebraic
> specification of a type.  Attributes on a type are part of the
> language environment inside of which a type specification is
> expressed.  These are very different.

"Dmitry A. Kazakov" <mail...@dmitry-kazakov.de> wrote:
> I don't see why this distinction is important.

I'm afraid I don't know how to argue this point briefly.  It's the
difference between language (in the proof theory sense) and
metalanguage.  I guess I've done too much formal logic too see this
distinction and its import as anything other than obvious.

Eric



  parent reply	other threads:[~2008-03-14  3:55 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-03-12 18:58 User-defined type attributes Eric Hughes
2008-03-12 21:23 ` Dmitry A. Kazakov
2008-03-13 18:32   ` Eric Hughes
2008-03-13 19:58     ` Dmitry A. Kazakov
2008-03-14  1:46       ` Randy Brukardt
2008-03-14  9:00         ` Dmitry A. Kazakov
2008-03-14 14:36           ` User-defined type attributes (replacing genericity) Georg Bauhaus
2008-03-15  3:04           ` User-defined type attributes Randy Brukardt
2008-03-15  9:33             ` Dmitry A. Kazakov
2008-03-14 14:31         ` User-defined type attributes (replacing genericity) Georg Bauhaus
2008-03-14 14:48           ` Dmitry A. Kazakov
2008-03-14 17:51             ` Eric Hughes
2008-03-14 18:58               ` Dmitry A. Kazakov
2008-03-14 20:19                 ` Eric Hughes
2008-03-15  4:01               ` Randy Brukardt
2008-03-14 16:58           ` Georg Bauhaus
2008-03-14 18:39             ` Dmitry A. Kazakov
2008-03-15  9:39               ` Dmitry A. Kazakov
2008-03-14  1:46       ` User-defined type attributes Randy Brukardt
2008-03-14  1:46       ` Randy Brukardt
2008-03-14  3:55       ` Eric Hughes [this message]
2008-03-14  9:01         ` Dmitry A. Kazakov
2008-03-14 18:04           ` Eric Hughes
2008-03-14  1:46 ` Randy Brukardt
2008-03-14  4:41   ` Eric Hughes
2008-03-15  3:20     ` Randy Brukardt
2008-03-17  4:38       ` Eric Hughes
2008-03-17 21:03         ` Randy Brukardt
2008-03-17 21:58           ` Eric Hughes
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox