[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#446470: gnat: Bug when using representation clauses



Package: gnat
Version: 4.1.2-11
Severity: normal

Hi,

I tried to compile the following procedure:

procedure Test_Param is
   type Int_1 is range 0 .. 600;
   for Int_1'Size use 10;

   type Int_2 is range 0 .. 8_191;
   for Int_2'Size use 13;

   type T_A_B is record
      A : Int_1;
      B : Int_2 range 0 .. 6_350;
   end record;
   for T_A_B'Size use 23;
   pragma Pack(T_A_B);

   type T_C is array (1..7) of T_A_B;
   for T_C'Size use 7 * 23;
   pragma Pack(T_C);

   X : T_C;
begin
   if X(1).B'Valid then
      null;
   end if;
end Test_Param;

But gnat told me to send a bug report. That is what I do now.

$ gnatmake test_param.adb
gcc-4.1 -c test_param.adb
+===========================GNAT BUG DETECTED==============================+
| 4.1.2 20061115 (prerelease) (Debian 4.1.1-22) (x86_64-pc-linux-gnu) GCC error:|
| in expand_expr_addr_expr_1, at expr.c:6393                               |
| Error detected at test_param.adb:24:5                                    |
| Please submit a bug report; see http://gcc.gnu.org/bugs.html.            |
| Use a subject line meaningful to you and us to track the bug.            |
| Include the entire contents of this bug box in the report.               |
| Include the exact gcc-4.1 or gnatmake command that you entered.          |
| Also include sources listed below in gnatchop format                     |
| (concatenated together with no headers between files).                   |
+==========================================================================+

Please include these source files with error report
Note that list may not be accurate in some cases,
so please double check that the problem can still
be reproduced with the set of files listed.

test_param.adb

compilation abandoned
gnatmake: "test_param.adb" compilation error


Thank you in adavance for correcting this problem,

Prakash Countcham

-- System Information:
Debian Release: 4.0
  APT prefers stable
  APT policy: (990, 'stable'), (500, 'testing')
Architecture: amd64 (x86_64)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.18-5-amd64
Locale: LANG=fr_FR, LC_CTYPE=fr_FR (charmap=ISO-8859-1)

Versions of packages gnat depends on:
ii  gnat-4.1                      4.1.1-22   The GNU Ada compiler

gnat recommends no packages.

-- no debconf information




Reply to: