aboutsummaryrefslogtreecommitdiff
path: root/gcc/expr.cc
diff options
context:
space:
mode:
authorGary Dismukes <dismukes@adacore.com>2025-01-08 22:51:41 +0000
committerMarc Poulhiès <dkm@gcc.gnu.org>2025-01-13 11:52:58 +0100
commitc6989fbbf2f195e874245409635a856d74bf6945 (patch)
tree534628888d0077081162344700a10e53f7642ba0 /gcc/expr.cc
parentf9d22b7ac734a917f3ee379336ad764ccd6f74ca (diff)
downloadgcc-c6989fbbf2f195e874245409635a856d74bf6945.zip
gcc-c6989fbbf2f195e874245409635a856d74bf6945.tar.gz
gcc-c6989fbbf2f195e874245409635a856d74bf6945.tar.bz2
ada: Unbounded recursion on character aggregates with predicated component subtype
The compiler was recursing endlessly when analyzing an aggregate of an array type whose component subtype has a static predicate and the component expressions are static, repeatedly transforming the aggregate first into a string literal and then back into an aggregate. This is fixed by suppressing the transformation to a string literal in the case where the component subtype has predicates. gcc/ada/ChangeLog: * sem_aggr.adb (Resolve_Aggregate): Add another condition to prevent rewriting an aggregate whose type is an array of characters, testing for the presence of predicates on the component type.
Diffstat (limited to 'gcc/expr.cc')
0 files changed, 0 insertions, 0 deletions