[clang] [Clang] Instantiate functions from constant evaluation. (PR #205557)
Corentin Jabot via cfe-commits
cfe-commits at lists.llvm.org
Wed Jun 24 07:18:41 PDT 2026
================
@@ -1452,6 +1453,15 @@ class VarDecl : public DeclaratorDecl, public Redeclarable<VarDecl> {
/// not.
bool evaluateDestruction(SmallVectorImpl<PartialDiagnosticAt> &Notes) const;
+ /// Evaluate the destruction of this variable, the destruction of which is
+ /// required by language rules to be constant.
+ ///
+ /// \pre hasConstantInitialization()
+ /// \return \c true if this variable has constant destruction, \c false if
+ /// not.
+ bool evaluateMandatedConstantDestruction(
+ SmallVectorImpl<PartialDiagnosticAt> &Notes, SemaProxy &SP) const;
----------------
cor3ntin wrote:
```suggestion
bool evaluateConstantDestruction(
SmallVectorImpl<PartialDiagnosticAt> &Notes, SemaProxy &SP) const;
```
https://github.com/llvm/llvm-project/pull/205557
More information about the cfe-commits
mailing list