[Bug ada/106168] New: Errors with empty array aggregate.
p.p11 at orange dot fr
gcc-bugzilla@gcc.gnu.org
Sat Jul 2 11:36:50 GMT 2022
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106168
Bug ID: 106168
Summary: Errors with empty array aggregate.
Product: gcc
Version: 12.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: ada
Assignee: unassigned at gcc dot gnu.org
Reporter: p.p11 at orange dot fr
Target Milestone: ---
Created attachment 53239
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=53239&action=edit
Full source code
Following the example section of RM Ada 2022 § 4.3.3 Array Aggregate, the empty
aggregate is line 8:
3. type Real is digits 8;
4. type Matrix is array (Integer range <>, Integer range <>) of Real;
5.
6. -- AARM (Draft 22) Section_4_3_3_Paragraph_47
7.
8. Empty_Matrix : constant Matrix := []; -- A matrix without elements
GNAT 12.1.0 issues the following errors:
% gcc -c -gnat2022 2022/test_20220702_array_agg.adb
test_20220702_array_agg.adb:8:38: error: value not in range of type
"Standard.Integer"
test_20220702_array_agg.adb:8:38: error: static expression fails
Constraint_Check
More information about the Gcc-bugs
mailing list