From: "Yannick Duchêne (Hibou57)" <yannick_duchene@yahoo.fr>
Subject: Re: Basic questions about wordings in “Interfacing Pragmas”
Date: Wed, 23 Nov 2011 05:39:21 +0100
Date: 2011-11-23T05:39:21+01:00 [thread overview]
Message-ID: <op.v5dtvvs4ule2fv@douda-yannick> (raw)
In-Reply-To: eb25b13e-cc4c-4dcb-9b74-1fcf379d5fee@v38g2000prh.googlegroups.com
Le Tue, 22 Nov 2011 21:07:53 +0100, Adam Beneschan <adam@irvine.com> a
écrit:
>> In notes at the bottom> 46 5 The local_name in an interfacing pragma
>> can denote more
>> > than one entity in the case of overloading. Such a pragma
>> > applies to all of the denoted entities.
>>
>> Why not the same with types derived from a type with an interfacing
>> pragma
>> ?
>
> Types can't be overloaded. Since you can declare more than one
> subprogram with the same name, the purpose of this note is to describe
> what happens if you use that name in one of these pragmas, in that
> case. There's no need for a similar rule about types.
Oops, I was misunderstood here.
Say T11 is tagged type. A pragma specify some convention for T11.
According to this RM page, then a type T12 extending (or not) T11, will
hold the same convention too.
Say T21 is a “classic” scalar type. A pragma specify some convention for
T21. According to this RM page, then a `type T22 is new T21;` will not
hold the same convention, because it is not denoted by the same same any
more, and it is not tagged.
I am not feeling fine with this: T12 will keep the convention, while T22
won't. T22 should too.
Similarly: formally (no compiler specific answer please), what about
`subtype T23 is T21;`. Not denoted by the same name too, so too not
warranted to still hold the convention specified for T21 ? If so, this is
another reason for me to not feeling OK.
--
“Syntactic sugar causes cancer of the semi-colons.” [Epigrams on
Programming — Alan J. — P. Yale University]
“Structured Programming supports the law of the excluded muddle.” [Idem]
next prev parent reply other threads:[~2011-11-23 4:39 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-22 18:15 Basic questions about wordings in “Interfacing Pragmas” Yannick Duchêne (Hibou57)
2011-11-22 18:18 ` Yannick Duchêne (Hibou57)
2011-11-22 19:10 ` AdaMagica
2011-11-23 4:28 ` Yannick Duchêne (Hibou57)
2011-11-22 20:07 ` Adam Beneschan
2011-11-23 4:39 ` Yannick Duchêne (Hibou57) [this message]
2011-11-23 6:05 ` Adam Beneschan
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox