diff options
author | Ghjuvan Lacambre <lacambre@adacore.com> | 2024-10-18 16:15:04 +0200 |
---|---|---|
committer | Marc Poulhiès <dkm@gcc.gnu.org> | 2024-11-12 14:00:45 +0100 |
commit | ca0f0154622c32123c57721b39bc9585119b02d7 (patch) | |
tree | 493caeec0ccacd5c5dbda90504cc220e31ae1613 /gcc/ada/raise-gcc.c | |
parent | ea497d17c11ee7465140aa13a18a0033ba5a2a27 (diff) | |
download | gcc-ca0f0154622c32123c57721b39bc9585119b02d7.zip gcc-ca0f0154622c32123c57721b39bc9585119b02d7.tar.gz gcc-ca0f0154622c32123c57721b39bc9585119b02d7.tar.bz2 |
ada: sem.adb.process_bodies_in_context: check if spec has lib body before use
Inspector testing shows that calling Body_Lib_Unit on Spec can sometimes
fail due to the following assertion failing:
pragma Assert
(Unit (N) in N_Lib_Unit_Declaration_Id
| N_Lib_Unit_Renaming_Declaration_Id);
Indeed, Unit (N) may sometimes be an N_Subprogram_Body instead of an
N_Lib_Unit_Declaration_Id.
gcc/ada/ChangeLog:
* sem.adb (Process_Bodies_In_Context): check that Spec's unit is
an N_Lib_Unit_Declaration_Id.
Diffstat (limited to 'gcc/ada/raise-gcc.c')
0 files changed, 0 insertions, 0 deletions