]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
[Ada] Remove redundant guard in expansion of dispatching calls
authorPiotr Trojanek <trojanek@adacore.com>
Fri, 8 Oct 2021 12:37:52 +0000 (14:37 +0200)
committerPierre-Marie de Rodat <derodat@adacore.com>
Mon, 25 Oct 2021 15:07:20 +0000 (15:07 +0000)
gcc/ada/

* exp_ch3.adb (Predefined_Primitive_Bodies): Remove redundant
conditions related to interface types.

gcc/ada/exp_ch3.adb

index e7eed282fbe7853771d68f33db0113f487c866cd..e8d4326ab8da115e4733d414842f3f4393d6a0be 100644 (file)
@@ -11102,7 +11102,6 @@ package body Exp_Ch3 is
       --  they may be ancestors of synchronized interface types).
 
       if Ada_Version >= Ada_2005
-        and then not Is_Interface (Tag_Typ)
         and then
           ((Is_Interface (Etype (Tag_Typ))
              and then Is_Limited_Record (Etype (Tag_Typ)))
@@ -11123,7 +11122,7 @@ package body Exp_Ch3 is
          Append_To (Res, Make_Disp_Timed_Select_Body        (Tag_Typ));
       end if;
 
-      if not Is_Limited_Type (Tag_Typ) and then not Is_Interface (Tag_Typ) then
+      if not Is_Limited_Type (Tag_Typ) then
 
          --  Body for equality