===================================================================
@@ -204,6 +204,13 @@
when others => null;
end case;
+ -- Nothing to do for the identifier in an object renaming declaration,
+ -- the renaming itself does not need atomic syncrhonization.
+
+ if Nkind (Parent (N)) = N_Object_Renaming_Declaration then
+ return;
+ end if;
+
-- Go ahead and set the flag
Set_Atomic_Sync_Required (N);
===================================================================
@@ -1344,6 +1344,13 @@
Set_Is_Volatile (Id, Is_Volatile_Object (Nam));
+ -- Also copy settings of Is_Atomic and Is_Independent
+
+ if Is_Entity_Name (Nam) then
+ Set_Is_Atomic (Id, Is_Atomic (Entity (Nam)));
+ Set_Is_Independent (Id, Is_Independent (Entity (Nam)));
+ end if;
+
-- Treat as volatile if we just set the Volatile flag
if Is_Volatile (Id)