From: Viljar Indus Date: Mon, 28 Jul 2025 13:06:27 +0000 (+0300) Subject: ada: Add default assertion level for assertions X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d57092f2f3331c333c92296661a310d0285bd576;p=thirdparty%2Fgcc.git ada: Add default assertion level for assertions To standardize the comparisson between the levels of ghost entities and levels of assertion pragmasTo standardize the comparisson between the levels of ghost entities and levels of assertion pragmas. gcc/ada/ChangeLog: * sem_ch13.adb (Analyze_Aspect_Specifications): add default assertion level to assertion aspects. * sem_prag.adb (Analyze_Pragma): Likewise. --- diff --git a/gcc/ada/sem_ch13.adb b/gcc/ada/sem_ch13.adb index ce76b7dca01..f0caf960269 100644 --- a/gcc/ada/sem_ch13.adb +++ b/gcc/ada/sem_ch13.adb @@ -3272,6 +3272,8 @@ package body Sem_Ch13 is goto Continue; else Check_Applicable_Policy (Aspect); + Set_Aspect_Ghost_Assertion_Level + (Aspect, Standard_Level_Default); end if; end if; diff --git a/gcc/ada/sem_prag.adb b/gcc/ada/sem_prag.adb index 8bb309e64cc..e73cdedb4f6 100644 --- a/gcc/ada/sem_prag.adb +++ b/gcc/ada/sem_prag.adb @@ -12734,6 +12734,8 @@ package body Sem_Prag is else Check_Applicable_Policy (N, Empty); + Set_Pragma_Ghost_Assertion_Level + (N, Standard_Level_Default); end if; end if;