================
@@ -358,6 +362,18 @@ class LifetimeChecker {
     }
   }
 
+  void reportLifetimeboundViolations() {
+    if (!isa<FunctionDecl>(FD))
+      return;
+    for (const ParmVarDecl *PVD : cast<FunctionDecl>(FD)->parameters()) {
+      if (!PVD->hasAttr<LifetimeBoundAttr>())
+        continue;
+      if (!PVD->getAttr<LifetimeBoundAttr>()->isImplicit() &&
----------------
Xazax-hun wrote:

Hmm, I wonder if this can ever happen, that we infer an implicit lifetime 
attribute and later cannot verify it? 

I wonder if we want to be notified of those cases, should this be turned into 
an assert?

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

Reply via email to