[flang-commits] [flang] [flang] Set SAVE attribute for EQUIVALENCEd symbols consistently. (PR #67078)

Peter Klausler via flang-commits flang-commits at lists.llvm.org
Fri Sep 22 14:34:39 PDT 2023


================
@@ -2390,7 +2390,7 @@ Symbol &ScopeHandler::MakeHostAssocSymbol(
   // These attributes can be redundantly reapplied without error
   // on the host-associated name, at most once (C815).
   symbol.implicitAttrs() =
-      symbol.attrs() & Attrs{Attr::ASYNCHRONOUS, Attr::VOLATILE};
+      symbol.attrs() & Attrs{Attr::ASYNCHRONOUS, Attr::VOLATILE, Attr::SAVE};
----------------
klausler wrote:

Have you tested that an explicit SAVE in the nested scope still creates a new symbol?

If it does, please at least change the comment before your change.

https://github.com/llvm/llvm-project/pull/67078


More information about the flang-commits mailing list