public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r14-3695] ada: Remove redundant guard against an empty list of interfaces
@ 2023-09-05 11:09 Marc Poulhi?s
0 siblings, 0 replies; only message in thread
From: Marc Poulhi?s @ 2023-09-05 11:09 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:e394afd4a584fb4546be3b79270620f79989a387
commit r14-3695-ge394afd4a584fb4546be3b79270620f79989a387
Author: Piotr Trojanek <trojanek@adacore.com>
Date: Wed Aug 23 15:53:07 2023 +0200
ada: Remove redundant guard against an empty list of interfaces
Code cleanup; semantics is unaffected.
gcc/ada/
* sem_type.adb (Iface_Present_In_Ancestor): Remove guard for empty list
of interfaces; the following loop will work just fine without it.
Diff:
---
gcc/ada/sem_type.adb | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/gcc/ada/sem_type.adb b/gcc/ada/sem_type.adb
index 00a64152df1c..bbdcd5f24b8a 100644
--- a/gcc/ada/sem_type.adb
+++ b/gcc/ada/sem_type.adb
@@ -2578,9 +2578,7 @@ package body Sem_Type is
end if;
loop
- if Present (Interfaces (E))
- and then not Is_Empty_Elmt_List (Interfaces (E))
- then
+ if Present (Interfaces (E)) then
Elmt := First_Elmt (Interfaces (E));
while Present (Elmt) loop
AI := Node (Elmt);
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-09-05 11:09 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-09-05 11:09 [gcc r14-3695] ada: Remove redundant guard against an empty list of interfaces Marc Poulhi?s
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).