Your message dated Tue, 20 Sep 2016 09:54:11 +0000
with message-id <e1bmhkh-0005vg...@franck.debian.org>
and subject line Bug#838315: Removed package(s) from unstable
has caused the Debian Bug report #812587,
regarding gnat: Fail to reconize types with an unrejected static size attribute
as compile time known size type.
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
As said in the bug title gnat fail to reconize some compile time known size
type as it in some circumstances.
Please see below a minimal test case striped down form a real case :
procedure Foo is
type Unbiased_T is range 0 .. 4
with Size => 3;
(Off, "size clause forces biased representation for ""Biased_T""");
type Biased_T is range 1 .. 4
with Size => 2;
(On, "size clause forces biased representation for ""Biased_T""");
type Biased_Or_Unbiased_T (Biased : Boolean) is
case Biased is
when True => Biased_Value : Biased_T;
when False => Unbiased_Value : Unbiased_T;
Convention => Ada,
Size => 3;
for Biased_Or_Unbiased_T use
Biased_Value at 0 range 1 .. 2;
Unbiased_Value at 0 range 0 .. 2;
(Value_1_Is_Biased : Boolean;
Value_2_Is_Biased : Boolean) is
Value_1 : Biased_Or_Unbiased_T (Value_2_Is_Biased);
Value_2 : Biased_Or_Unbiased_T (Value_2_Is_Biased);
with Size => 8,
for Hardware_Register_T use
Value_1 at 0 range 0 .. 2;
Value_2 at 0 range 3 .. 5;
Value_1_Is_Biased at 0 range 6 .. 6;
Value_2_Is_Biased at 0 range 7 .. 7;
When invoking gnatmake as this :
I get this output :
gcc-4.9 -c foo.adb
foo.adb:38:11: size clause not allowed for variable length type
foo.adb:42:28: component clause not allowed for variable length component
foo.adb:43:28: component clause not allowed for variable length component
gnatmake: "foo.adb" compilation error
But none of the types here are variable length.
By some little investigation I have found that all of the 3 reported errors
cames from the same place in the compiler code.
The function Size_Known_At_Compile_Time return False and should return True
in the file freeze.adb at line 2832 and line 5228.
I expected at least any type with a static unrejected size attribute or clause
to be considered having a Size_Known_At_Compile_Time.
The function Size_Known_At_Compile_Time itself defined in einfo.adb line 2892
just return a flag which seem to only be manipulated by the procedure
Set_Size_Known_At_Compile_Time also define in einfo.adb at line 5655.
I suspect a call to the procedure Set_Size_Known_At_Compile_Time should be
added somwhere in freese.adb when there is a size clause or attribute for a
type but there I am at my limit in my understanding of the compiler code.
I suspect this bug to be present in all architecture and I can at least
confirme it on gnat-4.9 for x86 and powerpc, gnat-4.6 on x86 and
In the hope this bug report will help.
-- System Information:
Debian Release: 8.2
APT prefers stable-updates
APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: i386 (i686)
Kernel: Linux 3.16.0-4-686-pae (SMP w/2 CPU cores)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages gnat depends on:
ii gnat-4.9 4.9.2-1
Versions of packages gnat recommends:
ii ada-reference-manual-2012 1:2012.2-3
ii gnat-gps 5.3dfsg-1
gnat suggests no packages.
-- no debconf information
--- End Message ---
--- Begin Message ---
as the package gnat-4.9 has just been removed from the Debian archive
unstable we hereby close the associated bug reports. We are sorry
that we couldn't deal with your issue properly.
For details on the removal, please see https://bugs.debian.org/838315
The version of this package that was in Debian prior to this removal
can still be found using http://snapshot.debian.org/.
This message was generated automatically; if you believe that there is
a problem with it please contact the archive administrators by mailing
Debian distribution maintenance software
Chris Lamb (the ftpmaster behind the curtain)
--- End Message ---