================
@@ -3678,20 +3690,63 @@ class CompoundLiteralExpr : public Expr {
   Expr *getInitializer() { return cast<Expr>(Init); }
   void setInitializer(Expr *E) { Init = E; }
 
-  bool isFileScope() const { return TInfoAndScope.getInt(); }
-  void setFileScope(bool FS) { TInfoAndScope.setInt(FS); }
+  ScopeKind getScopeKind() const { return TInfoAndScope.getInt(); }
+  void setScopeKind(ScopeKind Scope) { TInfoAndScope.setInt(Scope); }
+
+  bool isFileScope() const { return getScopeKind() == ScopeKind::File; }
 
   SourceLocation getLParenLoc() const { return LParenLoc; }
   void setLParenLoc(SourceLocation L) { LParenLoc = L; }
 
   TypeSourceInfo *getTypeSourceInfo() const {
     return TInfoAndScope.getPointer();
   }
-  void setTypeSourceInfo(TypeSourceInfo *tinfo) {
-    TInfoAndScope.setPointer(tinfo);
+
+  void setTypeSourceInfo(TypeSourceInfo *TInfo) {
+    TInfoAndScope.setPointer(TInfo);
+  }
+
+  bool hasStaticStorage() const {
+    return isGLValue() && !hasThreadStorage() &&
----------------
a-tarasyuk wrote:

Yes. From my understanding, `(static thread_local int){12}` has thread 
_storage_ duration, not static _storage_ duration. Is that correct?

https://github.com/llvm/llvm-project/pull/212559
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to