From: Brian May <bam@snoopy.apana.org.au>
Subject: Re: Discriminated types with default discriminants
Date: Fri, 04 Nov 2005 14:27:01 +1100
Date: 2005-11-04T14:27:01+11:00 [thread overview]
Message-ID: <sa4vez99jp6.fsf@snoopy.microcomaustralia.com.au> (raw)
In-Reply-To: dkdbjk$cd8$1@sunnews.cern.ch
>>>>> "Maciej" == Maciej Sobczak <no.spam@no.spam.com> writes:
Hello,
The 2nd warning has already been explained in detail, however I am
still confused with the first warning:
Maciej> Compiler (GNAT) gives me two warnings:
Maciej> 5. Value : String (1..Size);
Maciej> |
>>>> warning: creation of object of this type may raise
Maciej> Storage_Error
Why does this warning go away when using an unbounded subtype? Doesn't
the issue still exist?
Maciej> I can get rid of the first warning with this:
Maciej> subtype MyInt is Integer;
Maciej> type Discriminated(Size : MyInt := 10) is
Maciej> -- ...
Thanks
--
Brian May <bam@snoopy.apana.org.au>
next prev parent reply other threads:[~2005-11-04 3:27 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-11-03 15:50 Discriminated types with default discriminants Maciej Sobczak
2005-11-03 16:06 ` Martin Krischik
2005-11-03 23:10 ` Robert A Duff
2005-11-04 5:01 ` Jeffrey R. Carter
2005-11-03 16:21 ` Ed Falis
2005-11-03 17:28 ` Dmitry A. Kazakov
2005-11-03 18:51 ` Jeffrey R. Carter
2005-11-03 23:08 ` Robert A Duff
2005-11-04 0:08 ` Adam Beneschan
2005-11-29 2:49 ` Randy Brukardt
2005-12-02 18:22 ` Robert A Duff
2005-11-04 9:18 ` Maciej Sobczak
2005-11-04 3:27 ` Brian May [this message]
2005-11-04 13:09 ` Stephen Leake
2005-11-04 17:58 ` Martin Krischik
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox