From c4c57c9cbeda074a1e21d469575510791ed8667e Mon Sep 17 00:00:00 2001 From: Eric Botcazou Date: Sat, 26 May 2012 13:25:55 +0000 Subject: [PATCH] re PR ada/50294 (ICE in output_constructor_regular_field) PR ada/50294 * gnat.dg/array21.adb: New test. From-SVN: r187914 --- gcc/testsuite/ChangeLog | 5 +++++ gcc/testsuite/gnat.dg/array21.adb | 16 ++++++++++++++++ 2 files changed, 21 insertions(+) create mode 100644 gcc/testsuite/gnat.dg/array21.adb diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 0433d62b388..f3a3b73a577 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2012-05-26 Eric Botcazou + + PR ada/50294 + * gnat.dg/array21.adb: New test. + 2012-05-26 Eric Botcazou * gnat.dg/renaming5.adb: Adjust dg-final directive. diff --git a/gcc/testsuite/gnat.dg/array21.adb b/gcc/testsuite/gnat.dg/array21.adb new file mode 100644 index 00000000000..c642afdd119 --- /dev/null +++ b/gcc/testsuite/gnat.dg/array21.adb @@ -0,0 +1,16 @@ +-- { dg-do run } + +with System; + +procedure Array21 is + + type Index_T is mod System.Memory_Size; + type Arr + is array (Index_T range Index_T'Last/2-3 .. Index_T'Last/2+3) of Integer; + C : constant Arr := (1, others => 2); + +begin + if C /= (1, 2, 2, 2, 2, 2, 2) then + raise Program_Error; + end if; +end; -- 2.30.2