https://gcc.gnu.org/g:0bcca04f0947783df93386bbe22253092f3b0d52
commit r14-10869-g0bcca04f0947783df93386bbe22253092f3b0d52 Author: Eric Botcazou <ebotca...@adacore.com> Date: Mon Nov 4 11:15:15 2024 +0100 Add regression test This is for the latest fix made to Selected_Length_Checks in Checks. gcc/testsuite * gnat.dg/specs/array7.ads: New test. Diff: --- gcc/testsuite/gnat.dg/specs/array7.ads | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/gcc/testsuite/gnat.dg/specs/array7.ads b/gcc/testsuite/gnat.dg/specs/array7.ads new file mode 100644 index 000000000000..643ec3bb9ce5 --- /dev/null +++ b/gcc/testsuite/gnat.dg/specs/array7.ads @@ -0,0 +1,14 @@ +-- { dg-do compile } +-- { dg-options "-O" } + +package Array7 is + + type I is interface; + + type Rec (Name_Len : Natural) is new I with record + Input : String (1 .. Name_Len); + end record; + + function Image (R : Rec) return String is ("I" & String (R.Input)); + +end Array7;