[clang] [Clang] Implement P0963R3 "Structured binding declaration as a condition" (PR #130228)
Younan Zhang via cfe-commits
cfe-commits at lists.llvm.org
Mon Mar 10 02:12:31 PDT 2025
================
@@ -4224,15 +4224,18 @@ class DecompositionDecl final
: public VarDecl,
private llvm::TrailingObjects<DecompositionDecl, BindingDecl *> {
/// The number of BindingDecl*s following this object.
- unsigned NumBindings;
+ unsigned NumBindings : 31;
+
+ LLVM_PREFERRED_TYPE(bool)
+ unsigned IsDecisionVariable : 1;
----------------
zyn0217 wrote:
I tried that approach in the first place, but it turns out to bring significant churn in the evaluator's current structure. Adding a lot of bool flags on the caller side and since we have recursive calls, makes maintaining these flags become an additional burden. TBH I don't like it because I really feel it makes the code messy
https://github.com/llvm/llvm-project/pull/130228
More information about the cfe-commits
mailing list