From: Piotr Trojanek Date: Mon, 28 Jun 2021 20:34:10 +0000 (+0200) Subject: [Ada] Remove redundant checks for non-empty list of aspects X-Git-Tag: basepoints/gcc-13~4599 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=71a4bdada59d2d6d1f17c949eaf9377ebb7a8854;p=thirdparty%2Fgcc.git [Ada] Remove redundant checks for non-empty list of aspects gcc/ada/ * inline.adb (Has_Excluded_Declaration): Remove redundant guard; the guarded code will call First on a No_List, which is well-defined and gives Empty. --- diff --git a/gcc/ada/inline.adb b/gcc/ada/inline.adb index 84e2bc866b9c..773b376685b2 100644 --- a/gcc/ada/inline.adb +++ b/gcc/ada/inline.adb @@ -4319,9 +4319,7 @@ package body Inline is -- functions, i.e. nested subprogram bodies, so inlining is not -- possible. - elsif Nkind (Decl) = N_Subtype_Declaration - and then Present (Aspect_Specifications (Decl)) - then + elsif Nkind (Decl) = N_Subtype_Declaration then declare A : Node_Id; A_Id : Aspect_Id;