diff options
Diffstat (limited to 'gcc/ada/sem_util.adb')
-rw-r--r-- | gcc/ada/sem_util.adb | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/gcc/ada/sem_util.adb b/gcc/ada/sem_util.adb index 29ddee9..cc25e34 100644 --- a/gcc/ada/sem_util.adb +++ b/gcc/ada/sem_util.adb @@ -5712,7 +5712,14 @@ package body Sem_Util is -- Start of processing for Is_Atomic_Object begin - if Is_Atomic (Etype (N)) + -- Predicate is not relevant to subprograms + + if Is_Entity_Name (N) + and then Is_Overloadable (Entity (N)) + then + return False; + + elsif Is_Atomic (Etype (N)) or else (Is_Entity_Name (N) and then Is_Atomic (Entity (N))) then return True; |