* [Ada] Remove dead code for overlapping actuals and prefix notation
@ 2021-06-17 14:33 Pierre-Marie de Rodat
0 siblings, 0 replies; only message in thread
From: Pierre-Marie de Rodat @ 2021-06-17 14:33 UTC (permalink / raw)
To: gcc-patches; +Cc: Piotr Trojanek
[-- Attachment #1: Type: text/plain, Size: 338 bytes --]
In detection of overlapping actuals we first call Refer_Same_Object to
filter function calls that act as actual parameters. There is no need to
later special-case any function calls, e.g. in the prefix notation.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_warn.adb (Warn_On_Overlapping_Actuals): Remove dead code.
[-- Attachment #2: patch.diff --]
[-- Type: text/x-diff, Size: 550 bytes --]
diff --git a/gcc/ada/sem_warn.adb b/gcc/ada/sem_warn.adb
--- a/gcc/ada/sem_warn.adb
+++ b/gcc/ada/sem_warn.adb
@@ -3788,12 +3788,6 @@ package body Sem_Warn is
then
null;
- -- If the actual is a function call in prefix notation,
- -- there is no real overlap.
-
- elsif Nkind (Act2) = N_Function_Call then
- null;
-
-- If type is explicitly not by-copy, assume that
-- aliasing is intended.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2021-06-17 14:33 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-17 14:33 [Ada] Remove dead code for overlapping actuals and prefix notation Pierre-Marie de Rodat
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).