aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/init.c
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2022-05-06 22:48:04 +0200
committerPierre-Marie de Rodat <derodat@adacore.com>2022-06-01 08:43:18 +0000
commit66f2a0def548b7f2e4edb46e50fc0b72e84532cc (patch)
treecdcbff912d4a2ea1aa191c6566c83309daf63629 /gcc/ada/init.c
parent2ae98c3a75102cb4dbb9b8da690952a9971d4e93 (diff)
downloadgcc-66f2a0def548b7f2e4edb46e50fc0b72e84532cc.zip
gcc-66f2a0def548b7f2e4edb46e50fc0b72e84532cc.tar.gz
gcc-66f2a0def548b7f2e4edb46e50fc0b72e84532cc.tar.bz2
[Ada] Fix bad interaction between Inline_Always and -gnateV + -gnata
The combination of pragma/aspect Inline_Always and -gnateV -gnata runs afoul of the handling of inlining across units by gigi, which does not inline a subprogram that calls nested subprograms if these subprograms are not themselves inlined. This condition does not apply to internally generated subprograms but the special _postconditions procedure has Debug_Info_Needed set so it is not considered as such and, as a consequence, triggers an error if the enclosing subprogram requires inlining by means of Inline_Always. The _postconditions procedure is already marked inlined when generating C code so it makes sense to mark it inlined in the general case as well. gcc/ada/ * contracts.adb (Build_Postconditions_Procedure): Set Is_Inlined unconditionnally on the procedure entity.
Diffstat (limited to 'gcc/ada/init.c')
0 files changed, 0 insertions, 0 deletions