[clang] [LifetimeSafety] Warn on inapplicable [[clang::lifetimebound]] parameters (PR #201101)
Utkarsh Saxena via cfe-commits
cfe-commits at lists.llvm.org
Wed Jun 10 05:11:19 PDT 2026
================
@@ -0,0 +1,76 @@
+// RUN: %clang_cc1 -fsyntax-only -Wlifetime-safety-meaningless-lifetimebound -Wno-dangling -verify %s
+
----------------
usx95 wrote:
You are right that it should never fire. But we still want to test and document that behaviour to prevent future regressions. The reason it doesn't fire is that the object is a reference arg and we handle that.
https://github.com/llvm/llvm-project/pull/201101
More information about the cfe-commits
mailing list