]> git.ipfire.org Git - thirdparty/gcc.git/commit
Fix missing style violation report for package instantiation
authorEric Botcazou <ebotcazou@adacore.com>
Fri, 17 Oct 2025 09:02:28 +0000 (11:02 +0200)
committerEric Botcazou <ebotcazou@adacore.com>
Fri, 17 Oct 2025 09:05:08 +0000 (11:05 +0200)
commitcdb08b4bd24912f22c2f41798b3bd1b7395c87c6
tree63f1a93724dcb0736cff2d6201c3aa79c8682e81
parentc591c2aff5b84970833f84e2faf3f55f32a2c61f
Fix missing style violation report for package instantiation

Unlike for subprogram instantiation, -gnatyr does not report style violation
for package instantiation, more precisely for the generic package's name.

Fixing it uncovered style violations in the sources of the compiler itself!

gcc/ada/
PR ada/122295
* sem_ch12.adb (Analyze_Package_Instantiation): Force Style_Check
to False only after possibly installing the parent.
* aspects.adb (UAD_Pragma_Map): Fix style violation.
* inline.adb (To_Pending_Instantiations): Likewise.
* lib.ads (Unit_Names): Likewise.
* repinfo.adb (Relevant_Entities): Likewise.
* sem_ch7.adb (Subprogram_Table): Likewise.
(Traversed_Table): Likewise.
* sem_util.adb (Interval_Sorting): Likewise.

gcc/testsuite/
* gnat.dg/specs/style1.ads: New test.
gcc/ada/aspects.adb
gcc/ada/inline.adb
gcc/ada/lib.ads
gcc/ada/repinfo.adb
gcc/ada/sem_ch12.adb
gcc/ada/sem_ch7.adb
gcc/ada/sem_util.adb
gcc/testsuite/gnat.dg/specs/style1.ads [new file with mode: 0644]