http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57772

            Bug ID: 57772
           Summary: Bug box in gnat_to_gnu, at
                    ada/gcc-interface/trans.c:5778 on legal Ada 2005
                    quantifier expression with exponentiation
           Product: gcc
           Version: 4.6.4
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: ada
          Assignee: unassigned at gcc dot gnu.org
          Reporter: nicolas.boulenguez at free dot fr

The following program is legal in Ada2012 and illegal in Ada2005.
It crashes gcc with and without the -gnat12 flag.

Content of "p.ads":
package P is
   B : Boolean := (for all N in 1 .. 1 => 1**N = 1);
end P;

Output of "gnatmake p":
gcc-4.6 -c p.ads
+===========================GNAT BUG DETECTED==============================+
| 4.6.4 (x86_64-pc-linux-gnu) GCC error:                                   |
| in gnat_to_gnu, at ada/gcc-interface/trans.c:5778                        |
| Error detected at p.ads:2:44                                             |
and so on

Output of "gnatgcc -v":
Using built-in specs.
COLLECT_GCC=gnatgcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/4.6/lto-wrapper
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Debian 4.6.4-2'
--with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs
--enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr
--program-suffix=-4.6 --enable-shared --enable-linker-build-id
--with-system-zlib --libexecdir=/usr/lib --without-included-gettext
--enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6
--libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu
--enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object
--enable-plugin --enable-objc-gc --with-arch-32=i586 --with-tune=generic
--enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu
--target=x86_64-linux-gnu
Thread model: posix
gcc version 4.6.4 (Debian 4.6.4-2)

Reply via email to