https://gcc.gnu.org/bugzilla/show_bug.cgi?id=123138
--- Comment #4 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-15 branch has been updated by Eric Botcazou <[email protected]>: https://gcc.gnu.org/g:043ed7e185958510067698be29a549dff30fe326 commit r15-10604-g043ed7e185958510067698be29a549dff30fe326 Author: Eric Botcazou <[email protected]> Date: Tue Dec 16 00:34:31 2025 +0100 Ada: Fix ICE when comparing reduction expression with integer constant This a regression present on the mainline, 15 and 14 branches: the compiler aborts on the comparison of the result of a reduction expression, whose prefix is an aggregate, and an integer constant, because of a type mismatch created by the resolution of the reduction expression, which unduly forces Integer on the reduction expression. gcc/ada/ PR ada/123138 * exp_attr.adb (Expand_N_Attribute_Reference) <Attribute_Reduce>: Override a universal numeric type only if the prefix is not an aggregate. gcc/testsuite/ * gnat.dg/reduce4.adb: New test. * gnat.dg/reduce5.adb: Likewise.
