File tree Expand file tree Collapse file tree
cpp/ql/lib/semmle/code/cpp/ir/implementation/raw/internal Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -863,6 +863,15 @@ class TranslatedFieldAccess extends TranslatedVariableAccess {
863863 }
864864}
865865
866+ /**
867+ * The IR translation of a variable access of a structured binding, where the type
868+ * of the structured binding is not of a reference type, e.g., `x0` and `x1`
869+ * in `auto [x0, x1] = xs` where `xs` is an array. Although the type of the
870+ * structured binding is a non-reference type, the structured binding behaves
871+ * like a reference. Hence, the translation requires a `VariableAddress` followed
872+ * by a `Load` instead of only a `VariableAddress` as produced by
873+ * `TranslatedVariableAccess`.
874+ */
866875class TranslatedStructuredBindingVariableAccess extends TranslatedNonConstantExpr {
867876 override VariableAccess expr ;
868877
You can’t perform that action at this time.
0 commit comments