diff --git a/rust/ql/lib/codeql/rust/controlflow/internal/ControlFlowGraphImpl.qll b/rust/ql/lib/codeql/rust/controlflow/internal/ControlFlowGraphImpl.qll index 58cb9f6a95f..21497c24826 100644 --- a/rust/ql/lib/codeql/rust/controlflow/internal/ControlFlowGraphImpl.qll +++ b/rust/ql/lib/codeql/rust/controlflow/internal/ControlFlowGraphImpl.qll @@ -204,10 +204,18 @@ class TypeReprTree extends LeafTree instanceof TypeRepr { } * `LetExpr`s. */ module ExprTrees { - class ArrayExprTree extends StandardPostOrderTree, ArrayExpr { + class ArrayListExprTree extends StandardPostOrderTree, ArrayListExpr { override AstNode getChildNode(int i) { result = this.getExpr(i) } } + class ArrayRepeatExprTree extends StandardPostOrderTree, ArrayRepeatExpr { + override AstNode getChildNode(int i) { + i = 0 and result = this.getRepeatOperand() + or + i = 1 and result = this.getRepeatLength() + } + } + class AsmExprTree extends LeafTree instanceof AsmExpr { } class AwaitExprTree extends StandardPostOrderTree instanceof AwaitExpr {