From 0834e640bb1b39731dab096475e5570e30b89a6a Mon Sep 17 00:00:00 2001 From: Anders Schack-Mulligen Date: Fri, 19 Jun 2026 13:15:18 +0200 Subject: [PATCH 1/5] Ruby: Prepare qltest change by line renumbering. --- ruby/ql/test/library-tests/ast/Ast.expected | 602 ++++----- .../library-tests/ast/AstDesugar.expected | 546 ++++---- .../library-tests/ast/TreeSitter.expected | 1130 ++++++++--------- .../test/library-tests/ast/ValueText.expected | 288 ++--- .../ast/calls/arguments.expected | 46 +- .../library-tests/ast/calls/calls.expected | 528 ++++---- ruby/ql/test/library-tests/ast/calls/calls.rb | 6 +- 7 files changed, 1575 insertions(+), 1571 deletions(-) diff --git a/ruby/ql/test/library-tests/ast/Ast.expected b/ruby/ql/test/library-tests/ast/Ast.expected index da0a58f5d7d..341f4cf2cd3 100644 --- a/ruby/ql/test/library-tests/ast/Ast.expected +++ b/ruby/ql/test/library-tests/ast/Ast.expected @@ -445,351 +445,351 @@ calls/calls.rb: # 255| getEnsure: [StmtSequence] ensure ... # 255| getStmt: [MethodCall] call to bar # 255| getReceiver: [ConstantReadAccess] X -# 259| getStmt: [RescueModifierExpr] ... rescue ... -# 259| getBody: [MethodCall] call to foo -# 259| getReceiver: [SelfVariableAccess] self -# 259| getHandler: [MethodCall] call to bar -# 259| getReceiver: [SelfVariableAccess] self -# 260| getStmt: [RescueModifierExpr] ... rescue ... -# 260| getBody: [MethodCall] call to foo -# 260| getReceiver: [ConstantReadAccess] X -# 260| getHandler: [MethodCall] call to bar -# 260| getReceiver: [ConstantReadAccess] X -# 263| getStmt: [MethodCall] call to foo -# 263| getReceiver: [SelfVariableAccess] self -# 263| getArgument: [BlockArgument] &... -# 263| getValue: [MethodCall] call to bar -# 263| getReceiver: [SelfVariableAccess] self -# 264| getStmt: [MethodCall] call to foo -# 264| getReceiver: [SelfVariableAccess] self -# 264| getArgument: [BlockArgument] &... -# 264| getValue: [MethodCall] call to bar -# 264| getReceiver: [ConstantReadAccess] X -# 265| getStmt: [MethodCall] call to foo -# 265| getReceiver: [SelfVariableAccess] self -# 265| getArgument: [BlockArgument] &... +# 263| getStmt: [RescueModifierExpr] ... rescue ... +# 263| getBody: [MethodCall] call to foo +# 263| getReceiver: [SelfVariableAccess] self +# 263| getHandler: [MethodCall] call to bar +# 263| getReceiver: [SelfVariableAccess] self +# 264| getStmt: [RescueModifierExpr] ... rescue ... +# 264| getBody: [MethodCall] call to foo +# 264| getReceiver: [ConstantReadAccess] X +# 264| getHandler: [MethodCall] call to bar +# 264| getReceiver: [ConstantReadAccess] X # 267| getStmt: [MethodCall] call to foo # 267| getReceiver: [SelfVariableAccess] self -# 267| getArgument: [SplatExpr] * ... -# 267| getAnOperand/getOperand/getReceiver: [MethodCall] call to bar +# 267| getArgument: [BlockArgument] &... +# 267| getValue: [MethodCall] call to bar # 267| getReceiver: [SelfVariableAccess] self # 268| getStmt: [MethodCall] call to foo # 268| getReceiver: [SelfVariableAccess] self -# 268| getArgument: [SplatExpr] * ... -# 268| getAnOperand/getOperand/getReceiver: [MethodCall] call to bar +# 268| getArgument: [BlockArgument] &... +# 268| getValue: [MethodCall] call to bar # 268| getReceiver: [ConstantReadAccess] X # 269| getStmt: [MethodCall] call to foo # 269| getReceiver: [SelfVariableAccess] self -# 269| getArgument: [SplatExpr] * ... +# 269| getArgument: [BlockArgument] &... +# 271| getStmt: [MethodCall] call to foo +# 271| getReceiver: [SelfVariableAccess] self +# 271| getArgument: [SplatExpr] * ... +# 271| getAnOperand/getOperand/getReceiver: [MethodCall] call to bar +# 271| getReceiver: [SelfVariableAccess] self # 272| getStmt: [MethodCall] call to foo # 272| getReceiver: [SelfVariableAccess] self -# 272| getArgument: [HashSplatExpr] ** ... +# 272| getArgument: [SplatExpr] * ... # 272| getAnOperand/getOperand/getReceiver: [MethodCall] call to bar -# 272| getReceiver: [SelfVariableAccess] self +# 272| getReceiver: [ConstantReadAccess] X # 273| getStmt: [MethodCall] call to foo # 273| getReceiver: [SelfVariableAccess] self -# 273| getArgument: [HashSplatExpr] ** ... -# 273| getAnOperand/getOperand/getReceiver: [MethodCall] call to bar -# 273| getReceiver: [ConstantReadAccess] X -# 274| getStmt: [MethodCall] call to foo -# 274| getReceiver: [SelfVariableAccess] self -# 274| getArgument: [HashSplatExpr] ** ... +# 273| getArgument: [SplatExpr] * ... +# 276| getStmt: [MethodCall] call to foo +# 276| getReceiver: [SelfVariableAccess] self +# 276| getArgument: [HashSplatExpr] ** ... +# 276| getAnOperand/getOperand/getReceiver: [MethodCall] call to bar +# 276| getReceiver: [SelfVariableAccess] self # 277| getStmt: [MethodCall] call to foo # 277| getReceiver: [SelfVariableAccess] self -# 277| getArgument: [Pair] Pair -# 277| getKey: [SymbolLiteral] :blah -# 277| getComponent: [StringTextComponent] blah -# 277| getValue: [MethodCall] call to bar -# 277| getReceiver: [SelfVariableAccess] self +# 277| getArgument: [HashSplatExpr] ** ... +# 277| getAnOperand/getOperand/getReceiver: [MethodCall] call to bar +# 277| getReceiver: [ConstantReadAccess] X # 278| getStmt: [MethodCall] call to foo # 278| getReceiver: [SelfVariableAccess] self -# 278| getArgument: [Pair] Pair -# 278| getKey: [SymbolLiteral] :blah -# 278| getComponent: [StringTextComponent] blah -# 278| getValue: [MethodCall] call to bar -# 278| getReceiver: [ConstantReadAccess] X -# 283| getStmt: [ClassDeclaration] MyClass -# 284| getStmt: [Method] my_method -# 285| getBody: [StmtSequence] ... -# 285| getStmt: [SuperCall] super call to my_method -# 286| getStmt: [SuperCall] super call to my_method -# 287| getStmt: [SuperCall] super call to my_method -# 287| getArgument: [StringLiteral] "blah" -# 287| getComponent: [StringTextComponent] blah -# 288| getStmt: [SuperCall] super call to my_method -# 288| getArgument: [IntegerLiteral] 1 -# 288| getArgument: [IntegerLiteral] 2 -# 288| getArgument: [IntegerLiteral] 3 +# 278| getArgument: [HashSplatExpr] ** ... +# 281| getStmt: [MethodCall] call to foo +# 281| getReceiver: [SelfVariableAccess] self +# 281| getArgument: [Pair] Pair +# 281| getKey: [SymbolLiteral] :blah +# 281| getComponent: [StringTextComponent] blah +# 281| getValue: [MethodCall] call to bar +# 281| getReceiver: [SelfVariableAccess] self +# 282| getStmt: [MethodCall] call to foo +# 282| getReceiver: [SelfVariableAccess] self +# 282| getArgument: [Pair] Pair +# 282| getKey: [SymbolLiteral] :blah +# 282| getComponent: [StringTextComponent] blah +# 282| getValue: [MethodCall] call to bar +# 282| getReceiver: [ConstantReadAccess] X +# 287| getStmt: [ClassDeclaration] MyClass +# 288| getStmt: [Method] my_method +# 289| getBody: [StmtSequence] ... # 289| getStmt: [SuperCall] super call to my_method -# 289| getBlock: [BraceBlock] { ... } -# 289| getParameter: [SimpleParameter] x -# 289| getDefiningAccess: [LocalVariableAccess] x -# 289| getBody: [StmtSequence] ... -# 289| getStmt: [AddExpr] ... + ... -# 289| getAnOperand/getLeftOperand/getReceiver: [LocalVariableAccess] x -# 289| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 1 # 290| getStmt: [SuperCall] super call to my_method -# 290| getBlock: [DoBlock] do ... end -# 290| getParameter: [SimpleParameter] x -# 290| getDefiningAccess: [LocalVariableAccess] x -# 290| getBody: [StmtSequence] ... -# 290| getStmt: [MulExpr] ... * ... -# 290| getAnOperand/getLeftOperand/getReceiver: [LocalVariableAccess] x -# 290| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 2 # 291| getStmt: [SuperCall] super call to my_method -# 291| getArgument: [IntegerLiteral] 4 -# 291| getArgument: [IntegerLiteral] 5 -# 291| getBlock: [BraceBlock] { ... } -# 291| getParameter: [SimpleParameter] x -# 291| getDefiningAccess: [LocalVariableAccess] x -# 291| getBody: [StmtSequence] ... -# 291| getStmt: [AddExpr] ... + ... -# 291| getAnOperand/getLeftOperand/getReceiver: [LocalVariableAccess] x -# 291| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 100 +# 291| getArgument: [StringLiteral] "blah" +# 291| getComponent: [StringTextComponent] blah # 292| getStmt: [SuperCall] super call to my_method -# 292| getArgument: [IntegerLiteral] 6 -# 292| getArgument: [IntegerLiteral] 7 -# 292| getBlock: [DoBlock] do ... end -# 292| getParameter: [SimpleParameter] x -# 292| getDefiningAccess: [LocalVariableAccess] x -# 292| getBody: [StmtSequence] ... -# 292| getStmt: [AddExpr] ... + ... -# 292| getAnOperand/getLeftOperand/getReceiver: [LocalVariableAccess] x -# 292| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 200 -# 300| getStmt: [ClassDeclaration] AnotherClass -# 301| getStmt: [Method] another_method -# 302| getBody: [StmtSequence] ... -# 302| getStmt: [MethodCall] call to super -# 302| getReceiver: [MethodCall] call to foo -# 302| getReceiver: [SelfVariableAccess] self -# 303| getStmt: [MethodCall] call to super -# 303| getReceiver: [SelfVariableAccess] self -# 304| getStmt: [MethodCall] call to super -# 304| getReceiver: [SuperCall] super call to another_method -# 309| getStmt: [MethodCall] call to call -# 309| getReceiver: [MethodCall] call to foo -# 309| getReceiver: [SelfVariableAccess] self -# 310| getStmt: [MethodCall] call to call -# 310| getReceiver: [MethodCall] call to foo -# 310| getReceiver: [SelfVariableAccess] self -# 310| getArgument: [IntegerLiteral] 1 -# 313| getStmt: [AssignExpr] ... = ... -# 313| getAnOperand/getLeftOperand: [MethodCall] call to foo +# 292| getArgument: [IntegerLiteral] 1 +# 292| getArgument: [IntegerLiteral] 2 +# 292| getArgument: [IntegerLiteral] 3 +# 293| getStmt: [SuperCall] super call to my_method +# 293| getBlock: [BraceBlock] { ... } +# 293| getParameter: [SimpleParameter] x +# 293| getDefiningAccess: [LocalVariableAccess] x +# 293| getBody: [StmtSequence] ... +# 293| getStmt: [AddExpr] ... + ... +# 293| getAnOperand/getLeftOperand/getReceiver: [LocalVariableAccess] x +# 293| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 1 +# 294| getStmt: [SuperCall] super call to my_method +# 294| getBlock: [DoBlock] do ... end +# 294| getParameter: [SimpleParameter] x +# 294| getDefiningAccess: [LocalVariableAccess] x +# 294| getBody: [StmtSequence] ... +# 294| getStmt: [MulExpr] ... * ... +# 294| getAnOperand/getLeftOperand/getReceiver: [LocalVariableAccess] x +# 294| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 2 +# 295| getStmt: [SuperCall] super call to my_method +# 295| getArgument: [IntegerLiteral] 4 +# 295| getArgument: [IntegerLiteral] 5 +# 295| getBlock: [BraceBlock] { ... } +# 295| getParameter: [SimpleParameter] x +# 295| getDefiningAccess: [LocalVariableAccess] x +# 295| getBody: [StmtSequence] ... +# 295| getStmt: [AddExpr] ... + ... +# 295| getAnOperand/getLeftOperand/getReceiver: [LocalVariableAccess] x +# 295| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 100 +# 296| getStmt: [SuperCall] super call to my_method +# 296| getArgument: [IntegerLiteral] 6 +# 296| getArgument: [IntegerLiteral] 7 +# 296| getBlock: [DoBlock] do ... end +# 296| getParameter: [SimpleParameter] x +# 296| getDefiningAccess: [LocalVariableAccess] x +# 296| getBody: [StmtSequence] ... +# 296| getStmt: [AddExpr] ... + ... +# 296| getAnOperand/getLeftOperand/getReceiver: [LocalVariableAccess] x +# 296| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 200 +# 304| getStmt: [ClassDeclaration] AnotherClass +# 305| getStmt: [Method] another_method +# 306| getBody: [StmtSequence] ... +# 306| getStmt: [MethodCall] call to super +# 306| getReceiver: [MethodCall] call to foo +# 306| getReceiver: [SelfVariableAccess] self +# 307| getStmt: [MethodCall] call to super +# 307| getReceiver: [SelfVariableAccess] self +# 308| getStmt: [MethodCall] call to super +# 308| getReceiver: [SuperCall] super call to another_method +# 313| getStmt: [MethodCall] call to call +# 313| getReceiver: [MethodCall] call to foo # 313| getReceiver: [SelfVariableAccess] self -# 313| getAnOperand/getRightOperand: [IntegerLiteral] 10 -# 314| getStmt: [AssignExpr] ... = ... -# 314| getAnOperand/getLeftOperand: [ElementReference] ...[...] -# 314| getReceiver: [MethodCall] call to foo -# 314| getReceiver: [SelfVariableAccess] self -# 314| getArgument: [IntegerLiteral] 0 -# 314| getAnOperand/getRightOperand: [IntegerLiteral] 10 -# 315| getStmt: [AssignExpr] ... = ... -# 315| getAnOperand/getLeftOperand: [DestructuredLhsExpr] (..., ...) -# 315| getElement: [MethodCall] call to foo -# 315| getReceiver: [SelfVariableAccess] self -# 315| getElement: [MethodCall] call to bar -# 315| getReceiver: [SelfVariableAccess] self -# 315| getElement: [ElementReference] ...[...] -# 315| getReceiver: [MethodCall] call to foo -# 315| getReceiver: [SelfVariableAccess] self -# 315| getArgument: [IntegerLiteral] 4 -# 315| getAnOperand/getRightOperand: [ArrayLiteral] [...] -# 315| getElement: [IntegerLiteral] 1 -# 315| getElement: [IntegerLiteral] 2 -# 315| getElement: [IntegerLiteral] 3 -# 315| getElement: [IntegerLiteral] 4 -# 316| getStmt: [AssignExpr] ... = ... -# 316| getAnOperand/getLeftOperand: [DestructuredLhsExpr] (..., ...) -# 316| getElement: [LocalVariableAccess] a -# 316| getElement: [ElementReference] ...[...] -# 316| getReceiver: [MethodCall] call to foo -# 316| getReceiver: [SelfVariableAccess] self -# 316| getArgument: [IntegerLiteral] 5 -# 316| getAnOperand/getRightOperand: [ArrayLiteral] [...] -# 316| getElement: [IntegerLiteral] 1 -# 316| getElement: [IntegerLiteral] 2 -# 316| getElement: [IntegerLiteral] 3 -# 317| getStmt: [AssignAddExpr] ... += ... -# 317| getAnOperand/getLeftOperand: [MethodCall] call to count +# 314| getStmt: [MethodCall] call to call +# 314| getReceiver: [MethodCall] call to foo +# 314| getReceiver: [SelfVariableAccess] self +# 314| getArgument: [IntegerLiteral] 1 +# 317| getStmt: [AssignExpr] ... = ... +# 317| getAnOperand/getLeftOperand: [MethodCall] call to foo # 317| getReceiver: [SelfVariableAccess] self -# 317| getAnOperand/getRightOperand: [IntegerLiteral] 1 -# 318| getStmt: [AssignAddExpr] ... += ... +# 317| getAnOperand/getRightOperand: [IntegerLiteral] 10 +# 318| getStmt: [AssignExpr] ... = ... # 318| getAnOperand/getLeftOperand: [ElementReference] ...[...] # 318| getReceiver: [MethodCall] call to foo # 318| getReceiver: [SelfVariableAccess] self # 318| getArgument: [IntegerLiteral] 0 -# 318| getAnOperand/getRightOperand: [IntegerLiteral] 1 -# 319| getStmt: [AssignMulExpr] ... *= ... -# 319| getAnOperand/getLeftOperand: [ElementReference] ...[...] -# 319| getReceiver: [MethodCall] call to bar +# 318| getAnOperand/getRightOperand: [IntegerLiteral] 10 +# 319| getStmt: [AssignExpr] ... = ... +# 319| getAnOperand/getLeftOperand: [DestructuredLhsExpr] (..., ...) +# 319| getElement: [MethodCall] call to foo +# 319| getReceiver: [SelfVariableAccess] self +# 319| getElement: [MethodCall] call to bar +# 319| getReceiver: [SelfVariableAccess] self +# 319| getElement: [ElementReference] ...[...] # 319| getReceiver: [MethodCall] call to foo # 319| getReceiver: [SelfVariableAccess] self -# 319| getArgument: [IntegerLiteral] 0 -# 319| getArgument: [MethodCall] call to baz -# 319| getReceiver: [MethodCall] call to foo -# 319| getReceiver: [SelfVariableAccess] self -# 319| getArgument: [AddExpr] ... + ... -# 319| getAnOperand/getLeftOperand/getReceiver: [MethodCall] call to boo -# 319| getReceiver: [MethodCall] call to foo -# 319| getReceiver: [SelfVariableAccess] self -# 319| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 1 -# 319| getAnOperand/getRightOperand: [IntegerLiteral] 2 -# 322| getStmt: [Method] foo -# 322| getBody: [StmtSequence] ... -# 322| getStmt: [MethodCall] call to bar +# 319| getArgument: [IntegerLiteral] 4 +# 319| getAnOperand/getRightOperand: [ArrayLiteral] [...] +# 319| getElement: [IntegerLiteral] 1 +# 319| getElement: [IntegerLiteral] 2 +# 319| getElement: [IntegerLiteral] 3 +# 319| getElement: [IntegerLiteral] 4 +# 320| getStmt: [AssignExpr] ... = ... +# 320| getAnOperand/getLeftOperand: [DestructuredLhsExpr] (..., ...) +# 320| getElement: [LocalVariableAccess] a +# 320| getElement: [ElementReference] ...[...] +# 320| getReceiver: [MethodCall] call to foo +# 320| getReceiver: [SelfVariableAccess] self +# 320| getArgument: [IntegerLiteral] 5 +# 320| getAnOperand/getRightOperand: [ArrayLiteral] [...] +# 320| getElement: [IntegerLiteral] 1 +# 320| getElement: [IntegerLiteral] 2 +# 320| getElement: [IntegerLiteral] 3 +# 321| getStmt: [AssignAddExpr] ... += ... +# 321| getAnOperand/getLeftOperand: [MethodCall] call to count +# 321| getReceiver: [SelfVariableAccess] self +# 321| getAnOperand/getRightOperand: [IntegerLiteral] 1 +# 322| getStmt: [AssignAddExpr] ... += ... +# 322| getAnOperand/getLeftOperand: [ElementReference] ...[...] +# 322| getReceiver: [MethodCall] call to foo # 322| getReceiver: [SelfVariableAccess] self -# 323| getStmt: [Method] foo -# 323| getBody: [StmtSequence] ... -# 323| getStmt: [MethodCall] call to bar -# 323| getReceiver: [SelfVariableAccess] self -# 324| getStmt: [Method] foo -# 324| getBody: [StmtSequence] ... -# 324| getStmt: [MethodCall] call to bar -# 324| getReceiver: [SelfVariableAccess] self -# 324| getParameter: [SimpleParameter] x -# 324| getDefiningAccess: [LocalVariableAccess] x -# 325| getStmt: [SingletonMethod] foo -# 325| getBody: [StmtSequence] ... -# 325| getStmt: [MethodCall] call to bar -# 325| getReceiver: [SelfVariableAccess] self -# 325| getObject: [ConstantReadAccess] Object -# 326| getStmt: [SingletonMethod] foo +# 322| getArgument: [IntegerLiteral] 0 +# 322| getAnOperand/getRightOperand: [IntegerLiteral] 1 +# 323| getStmt: [AssignMulExpr] ... *= ... +# 323| getAnOperand/getLeftOperand: [ElementReference] ...[...] +# 323| getReceiver: [MethodCall] call to bar +# 323| getReceiver: [MethodCall] call to foo +# 323| getReceiver: [SelfVariableAccess] self +# 323| getArgument: [IntegerLiteral] 0 +# 323| getArgument: [MethodCall] call to baz +# 323| getReceiver: [MethodCall] call to foo +# 323| getReceiver: [SelfVariableAccess] self +# 323| getArgument: [AddExpr] ... + ... +# 323| getAnOperand/getLeftOperand/getReceiver: [MethodCall] call to boo +# 323| getReceiver: [MethodCall] call to foo +# 323| getReceiver: [SelfVariableAccess] self +# 323| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 1 +# 323| getAnOperand/getRightOperand: [IntegerLiteral] 2 +# 326| getStmt: [Method] foo # 326| getBody: [StmtSequence] ... # 326| getStmt: [MethodCall] call to bar # 326| getReceiver: [SelfVariableAccess] self -# 326| getObject: [ConstantReadAccess] Object -# 326| getParameter: [SimpleParameter] x -# 326| getDefiningAccess: [LocalVariableAccess] x # 327| getStmt: [Method] foo # 327| getBody: [StmtSequence] ... -# 327| getStmt: [RescueModifierExpr] ... rescue ... -# 327| getBody: [MethodCall] call to bar -# 327| getReceiver: [SelfVariableAccess] self -# 327| getHandler: [ParenthesizedExpr] ( ... ) -# 327| getStmt: [MethodCall] call to print -# 327| getReceiver: [SelfVariableAccess] self -# 327| getArgument: [StringLiteral] "error" -# 327| getComponent: [StringTextComponent] error -# 330| getStmt: [Method] foo -# 330| getParameter: [ForwardParameter] ... +# 327| getStmt: [MethodCall] call to bar +# 327| getReceiver: [SelfVariableAccess] self +# 328| getStmt: [Method] foo +# 328| getBody: [StmtSequence] ... +# 328| getStmt: [MethodCall] call to bar +# 328| getReceiver: [SelfVariableAccess] self +# 328| getParameter: [SimpleParameter] x +# 328| getDefiningAccess: [LocalVariableAccess] x +# 329| getStmt: [SingletonMethod] foo +# 329| getBody: [StmtSequence] ... +# 329| getStmt: [MethodCall] call to bar +# 329| getReceiver: [SelfVariableAccess] self +# 329| getObject: [ConstantReadAccess] Object +# 330| getStmt: [SingletonMethod] foo +# 330| getBody: [StmtSequence] ... +# 330| getStmt: [MethodCall] call to bar +# 330| getReceiver: [SelfVariableAccess] self +# 330| getObject: [ConstantReadAccess] Object +# 330| getParameter: [SimpleParameter] x +# 330| getDefiningAccess: [LocalVariableAccess] x +# 331| getStmt: [Method] foo # 331| getBody: [StmtSequence] ... -# 331| getStmt: [SuperCall] super call to foo -# 331| getArgument: [ForwardedArguments] ... +# 331| getStmt: [RescueModifierExpr] ... rescue ... +# 331| getBody: [MethodCall] call to bar +# 331| getReceiver: [SelfVariableAccess] self +# 331| getHandler: [ParenthesizedExpr] ( ... ) +# 331| getStmt: [MethodCall] call to print +# 331| getReceiver: [SelfVariableAccess] self +# 331| getArgument: [StringLiteral] "error" +# 331| getComponent: [StringTextComponent] error # 334| getStmt: [Method] foo -# 334| getParameter: [SimpleParameter] a -# 334| getDefiningAccess: [LocalVariableAccess] a -# 334| getParameter: [SimpleParameter] b -# 334| getDefiningAccess: [LocalVariableAccess] b # 334| getParameter: [ForwardParameter] ... # 335| getBody: [StmtSequence] ... -# 335| getStmt: [MethodCall] call to bar -# 335| getReceiver: [SelfVariableAccess] self -# 335| getArgument: [LocalVariableAccess] b +# 335| getStmt: [SuperCall] super call to foo # 335| getArgument: [ForwardedArguments] ... -# 339| getStmt: [ForExpr] for ... in ... -# 339| getPattern: [DestructuredLhsExpr] (..., ...) -# 339| getElement: [LocalVariableAccess] x -# 339| getElement: [LocalVariableAccess] y -# 339| getElement: [LocalVariableAccess] z -# 339| getValue: [ArrayLiteral] [...] -# 339| getElement: [ArrayLiteral] [...] -# 339| getElement: [IntegerLiteral] 1 -# 339| getElement: [IntegerLiteral] 2 -# 339| getElement: [IntegerLiteral] 3 -# 339| getElement: [ArrayLiteral] [...] -# 339| getElement: [IntegerLiteral] 4 -# 339| getElement: [IntegerLiteral] 5 -# 339| getElement: [IntegerLiteral] 6 -# 339| getBody: [StmtSequence] do ... -# 340| getStmt: [MethodCall] call to foo -# 340| getReceiver: [SelfVariableAccess] self -# 340| getArgument: [LocalVariableAccess] x -# 340| getArgument: [LocalVariableAccess] y -# 340| getArgument: [LocalVariableAccess] z -# 343| getStmt: [MethodCall] call to foo -# 343| getReceiver: [SelfVariableAccess] self -# 343| getArgument: [Pair] Pair -# 343| getKey: [SymbolLiteral] :x -# 343| getComponent: [StringTextComponent] x -# 343| getValue: [IntegerLiteral] 42 -# 344| getStmt: [MethodCall] call to foo -# 344| getReceiver: [SelfVariableAccess] self -# 344| getArgument: [Pair] Pair -# 344| getKey: [SymbolLiteral] :x -# 344| getComponent: [StringTextComponent] x -# 344| getValue: [LocalVariableAccess] x -# 344| getArgument: [Pair] Pair -# 344| getKey: [SymbolLiteral] :novar -# 344| getComponent: [StringTextComponent] novar -# 344| getValue: [MethodCall] call to novar -# 345| getStmt: [MethodCall] call to foo -# 345| getReceiver: [SelfVariableAccess] self -# 345| getArgument: [Pair] Pair -# 345| getKey: [SymbolLiteral] :X -# 345| getComponent: [StringTextComponent] X -# 345| getValue: [IntegerLiteral] 42 -# 346| getStmt: [MethodCall] call to foo -# 346| getReceiver: [SelfVariableAccess] self -# 346| getArgument: [Pair] Pair -# 346| getKey: [SymbolLiteral] :X -# 346| getComponent: [StringTextComponent] X -# 346| getValue: [ConstantReadAccess] X -# 349| getStmt: [AssignExpr] ... = ... -# 349| getAnOperand/getLeftOperand: [LocalVariableAccess] y -# 349| getAnOperand/getRightOperand: [IntegerLiteral] 1 -# 350| getStmt: [AssignExpr] ... = ... -# 350| getAnOperand/getLeftOperand: [LocalVariableAccess] one -# 350| getAnOperand/getRightOperand: [Lambda] -> { ... } -# 350| getParameter: [SimpleParameter] x -# 350| getDefiningAccess: [LocalVariableAccess] x -# 350| getBody: [StmtSequence] ... -# 350| getStmt: [LocalVariableAccess] y -# 351| getStmt: [AssignExpr] ... = ... -# 351| getAnOperand/getLeftOperand: [LocalVariableAccess] f -# 351| getAnOperand/getRightOperand: [Lambda] -> { ... } -# 351| getParameter: [SimpleParameter] x -# 351| getDefiningAccess: [LocalVariableAccess] x -# 351| getBody: [StmtSequence] ... -# 351| getStmt: [MethodCall] call to foo -# 351| getReceiver: [SelfVariableAccess] self -# 351| getArgument: [LocalVariableAccess] x -# 352| getStmt: [AssignExpr] ... = ... -# 352| getAnOperand/getLeftOperand: [LocalVariableAccess] g -# 352| getAnOperand/getRightOperand: [Lambda] -> { ... } -# 352| getParameter: [SimpleParameter] x -# 352| getDefiningAccess: [LocalVariableAccess] x -# 352| getBody: [StmtSequence] ... -# 352| getStmt: [MethodCall] call to unknown_call -# 352| getReceiver: [SelfVariableAccess] self +# 338| getStmt: [Method] foo +# 338| getParameter: [SimpleParameter] a +# 338| getDefiningAccess: [LocalVariableAccess] a +# 338| getParameter: [SimpleParameter] b +# 338| getDefiningAccess: [LocalVariableAccess] b +# 338| getParameter: [ForwardParameter] ... +# 339| getBody: [StmtSequence] ... +# 339| getStmt: [MethodCall] call to bar +# 339| getReceiver: [SelfVariableAccess] self +# 339| getArgument: [LocalVariableAccess] b +# 339| getArgument: [ForwardedArguments] ... +# 343| getStmt: [ForExpr] for ... in ... +# 343| getPattern: [DestructuredLhsExpr] (..., ...) +# 343| getElement: [LocalVariableAccess] x +# 343| getElement: [LocalVariableAccess] y +# 343| getElement: [LocalVariableAccess] z +# 343| getValue: [ArrayLiteral] [...] +# 343| getElement: [ArrayLiteral] [...] +# 343| getElement: [IntegerLiteral] 1 +# 343| getElement: [IntegerLiteral] 2 +# 343| getElement: [IntegerLiteral] 3 +# 343| getElement: [ArrayLiteral] [...] +# 343| getElement: [IntegerLiteral] 4 +# 343| getElement: [IntegerLiteral] 5 +# 343| getElement: [IntegerLiteral] 6 +# 343| getBody: [StmtSequence] do ... +# 344| getStmt: [MethodCall] call to foo +# 344| getReceiver: [SelfVariableAccess] self +# 344| getArgument: [LocalVariableAccess] x +# 344| getArgument: [LocalVariableAccess] y +# 344| getArgument: [LocalVariableAccess] z +# 347| getStmt: [MethodCall] call to foo +# 347| getReceiver: [SelfVariableAccess] self +# 347| getArgument: [Pair] Pair +# 347| getKey: [SymbolLiteral] :x +# 347| getComponent: [StringTextComponent] x +# 347| getValue: [IntegerLiteral] 42 +# 348| getStmt: [MethodCall] call to foo +# 348| getReceiver: [SelfVariableAccess] self +# 348| getArgument: [Pair] Pair +# 348| getKey: [SymbolLiteral] :x +# 348| getComponent: [StringTextComponent] x +# 348| getValue: [LocalVariableAccess] x +# 348| getArgument: [Pair] Pair +# 348| getKey: [SymbolLiteral] :novar +# 348| getComponent: [StringTextComponent] novar +# 348| getValue: [MethodCall] call to novar +# 349| getStmt: [MethodCall] call to foo +# 349| getReceiver: [SelfVariableAccess] self +# 349| getArgument: [Pair] Pair +# 349| getKey: [SymbolLiteral] :X +# 349| getComponent: [StringTextComponent] X +# 349| getValue: [IntegerLiteral] 42 +# 350| getStmt: [MethodCall] call to foo +# 350| getReceiver: [SelfVariableAccess] self +# 350| getArgument: [Pair] Pair +# 350| getKey: [SymbolLiteral] :X +# 350| getComponent: [StringTextComponent] X +# 350| getValue: [ConstantReadAccess] X # 353| getStmt: [AssignExpr] ... = ... -# 353| getAnOperand/getLeftOperand: [LocalVariableAccess] h -# 353| getAnOperand/getRightOperand: [Lambda] -> { ... } -# 353| getParameter: [SimpleParameter] x -# 353| getDefiningAccess: [LocalVariableAccess] x +# 353| getAnOperand/getLeftOperand: [LocalVariableAccess] y +# 353| getAnOperand/getRightOperand: [IntegerLiteral] 1 +# 354| getStmt: [AssignExpr] ... = ... +# 354| getAnOperand/getLeftOperand: [LocalVariableAccess] one +# 354| getAnOperand/getRightOperand: [Lambda] -> { ... } +# 354| getParameter: [SimpleParameter] x +# 354| getDefiningAccess: [LocalVariableAccess] x # 354| getBody: [StmtSequence] ... -# 354| getStmt: [LocalVariableAccess] x -# 355| getStmt: [LocalVariableAccess] y +# 354| getStmt: [LocalVariableAccess] y +# 355| getStmt: [AssignExpr] ... = ... +# 355| getAnOperand/getLeftOperand: [LocalVariableAccess] f +# 355| getAnOperand/getRightOperand: [Lambda] -> { ... } +# 355| getParameter: [SimpleParameter] x +# 355| getDefiningAccess: [LocalVariableAccess] x +# 355| getBody: [StmtSequence] ... +# 355| getStmt: [MethodCall] call to foo +# 355| getReceiver: [SelfVariableAccess] self +# 355| getArgument: [LocalVariableAccess] x +# 356| getStmt: [AssignExpr] ... = ... +# 356| getAnOperand/getLeftOperand: [LocalVariableAccess] g +# 356| getAnOperand/getRightOperand: [Lambda] -> { ... } +# 356| getParameter: [SimpleParameter] x +# 356| getDefiningAccess: [LocalVariableAccess] x +# 356| getBody: [StmtSequence] ... # 356| getStmt: [MethodCall] call to unknown_call # 356| getReceiver: [SelfVariableAccess] self -# 360| getStmt: [MethodCall] call to empty? -# 360| getReceiver: [MethodCall] call to list -# 360| getReceiver: [SelfVariableAccess] self -# 361| getStmt: [MethodCall] call to empty? -# 361| getReceiver: [MethodCall] call to list -# 361| getReceiver: [SelfVariableAccess] self -# 362| getStmt: [MethodCall] call to empty? -# 362| getReceiver: [MethodCall] call to list -# 362| getReceiver: [SelfVariableAccess] self -# 363| getStmt: [MethodCall] call to bar -# 363| getReceiver: [MethodCall] call to foo -# 363| getReceiver: [SelfVariableAccess] self -# 363| getArgument: [IntegerLiteral] 1 -# 363| getArgument: [IntegerLiteral] 2 -# 363| getBlock: [BraceBlock] { ... } -# 363| getParameter: [SimpleParameter] x -# 363| getDefiningAccess: [LocalVariableAccess] x -# 363| getBody: [StmtSequence] ... -# 363| getStmt: [LocalVariableAccess] x +# 357| getStmt: [AssignExpr] ... = ... +# 357| getAnOperand/getLeftOperand: [LocalVariableAccess] h +# 357| getAnOperand/getRightOperand: [Lambda] -> { ... } +# 357| getParameter: [SimpleParameter] x +# 357| getDefiningAccess: [LocalVariableAccess] x +# 358| getBody: [StmtSequence] ... +# 358| getStmt: [LocalVariableAccess] x +# 359| getStmt: [LocalVariableAccess] y +# 360| getStmt: [MethodCall] call to unknown_call +# 360| getReceiver: [SelfVariableAccess] self +# 364| getStmt: [MethodCall] call to empty? +# 364| getReceiver: [MethodCall] call to list +# 364| getReceiver: [SelfVariableAccess] self +# 365| getStmt: [MethodCall] call to empty? +# 365| getReceiver: [MethodCall] call to list +# 365| getReceiver: [SelfVariableAccess] self +# 366| getStmt: [MethodCall] call to empty? +# 366| getReceiver: [MethodCall] call to list +# 366| getReceiver: [SelfVariableAccess] self +# 367| getStmt: [MethodCall] call to bar +# 367| getReceiver: [MethodCall] call to foo +# 367| getReceiver: [SelfVariableAccess] self +# 367| getArgument: [IntegerLiteral] 1 +# 367| getArgument: [IntegerLiteral] 2 +# 367| getBlock: [BraceBlock] { ... } +# 367| getParameter: [SimpleParameter] x +# 367| getDefiningAccess: [LocalVariableAccess] x +# 367| getBody: [StmtSequence] ... +# 367| getStmt: [LocalVariableAccess] x control/cases.rb: # 1| [Toplevel] cases.rb # 2| getStmt: [AssignExpr] ... = ... diff --git a/ruby/ql/test/library-tests/ast/AstDesugar.expected b/ruby/ql/test/library-tests/ast/AstDesugar.expected index bd350dc0070..b058d7d12da 100644 --- a/ruby/ql/test/library-tests/ast/AstDesugar.expected +++ b/ruby/ql/test/library-tests/ast/AstDesugar.expected @@ -78,293 +78,293 @@ calls/calls.rb: # 246| getReceiver: [ConstantReadAccess] X # 246| getValue: [MethodCall] call to bar # 246| getReceiver: [ConstantReadAccess] X -# 313| [AssignExpr] ... = ... -# 313| getDesugared: [StmtSequence] ... -# 313| getStmt: [SetterMethodCall] call to foo= -# 313| getReceiver: [SelfVariableAccess] self -# 313| getArgument: [AssignExpr] ... = ... -# 313| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 -# 313| getAnOperand/getRightOperand: [IntegerLiteral] 10 -# 313| getStmt: [LocalVariableAccess] __synth__0 -# 314| [AssignExpr] ... = ... -# 314| getDesugared: [StmtSequence] ... -# 314| getStmt: [SetterMethodCall] call to []= -# 314| getReceiver: [MethodCall] call to foo -# 314| getReceiver: [SelfVariableAccess] self -# 314| getArgument: [IntegerLiteral] 0 -# 314| getArgument: [AssignExpr] ... = ... -# 314| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 -# 314| getAnOperand/getRightOperand: [IntegerLiteral] 10 -# 314| getStmt: [LocalVariableAccess] __synth__0 -# 315| [AssignExpr] ... = ... -# 315| getDesugared: [StmtSequence] ... -# 315| getStmt: [AssignExpr] ... = ... -# 315| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 -# 315| getAnOperand/getRightOperand: [SelfVariableAccess] self -# 315| getStmt: [AssignExpr] ... = ... -# 315| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__1 -# 315| getAnOperand/getRightOperand: [SelfVariableAccess] self -# 315| getStmt: [AssignExpr] ... = ... -# 315| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__2 -# 315| getAnOperand/getRightOperand: [MethodCall] call to foo -# 315| getReceiver: [SelfVariableAccess] self -# 315| getStmt: [AssignExpr] ... = ... -# 315| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__3 -# 315| getAnOperand/getRightOperand: [SplatExpr] * ... -# 315| getAnOperand/getOperand/getReceiver: [ArrayLiteral] [...] -# 315| getDesugared: [MethodCall] call to [] -# 315| getReceiver: [ConstantReadAccess] Array -# 315| getArgument: [IntegerLiteral] 1 -# 315| getArgument: [IntegerLiteral] 2 -# 315| getArgument: [IntegerLiteral] 3 -# 315| getArgument: [IntegerLiteral] 4 -# 315| getStmt: [AssignExpr] ... = ... -# 315| getDesugared: [StmtSequence] ... -# 315| getStmt: [SetterMethodCall] call to foo= -# 315| getReceiver: [LocalVariableAccess] __synth__0 -# 315| getArgument: [AssignExpr] ... = ... -# 315| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 -# 315| getAnOperand/getRightOperand: [MethodCall] call to [] -# 315| getReceiver: [LocalVariableAccess] __synth__3 -# 315| getArgument: [IntegerLiteral] 0 -# 315| getStmt: [LocalVariableAccess] __synth__0__1 -# 315| getAnOperand/getLeftOperand: [MethodCall] call to foo -# 315| getStmt: [AssignExpr] ... = ... -# 315| getDesugared: [StmtSequence] ... -# 315| getStmt: [SetterMethodCall] call to bar= -# 315| getReceiver: [LocalVariableAccess] __synth__1 -# 315| getArgument: [AssignExpr] ... = ... -# 315| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 -# 315| getAnOperand/getRightOperand: [MethodCall] call to [] -# 315| getReceiver: [LocalVariableAccess] __synth__3 -# 315| getArgument: [RangeLiteral] _ .. _ -# 315| getBegin: [IntegerLiteral] 1 -# 315| getEnd: [IntegerLiteral] -2 -# 315| getStmt: [LocalVariableAccess] __synth__0__1 -# 315| getAnOperand/getLeftOperand: [MethodCall] call to bar -# 315| getStmt: [AssignExpr] ... = ... -# 315| getDesugared: [StmtSequence] ... -# 315| getStmt: [SetterMethodCall] call to []= -# 315| getReceiver: [LocalVariableAccess] __synth__2 -# 315| getArgument: [IntegerLiteral] 4 -# 315| getArgument: [AssignExpr] ... = ... -# 315| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 -# 315| getAnOperand/getRightOperand: [MethodCall] call to [] -# 315| getReceiver: [LocalVariableAccess] __synth__3 -# 315| getArgument: [IntegerLiteral] -1 -# 315| getStmt: [LocalVariableAccess] __synth__0__1 -# 315| getAnOperand/getLeftOperand: [MethodCall] call to [] -# 316| [AssignExpr] ... = ... -# 316| getDesugared: [StmtSequence] ... -# 316| getStmt: [AssignExpr] ... = ... -# 316| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__1 -# 316| getAnOperand/getRightOperand: [MethodCall] call to foo -# 316| getReceiver: [SelfVariableAccess] self -# 316| getStmt: [AssignExpr] ... = ... -# 316| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__2 -# 316| getAnOperand/getRightOperand: [SplatExpr] * ... -# 316| getAnOperand/getOperand/getReceiver: [ArrayLiteral] [...] -# 316| getDesugared: [MethodCall] call to [] -# 316| getReceiver: [ConstantReadAccess] Array -# 316| getArgument: [IntegerLiteral] 1 -# 316| getArgument: [IntegerLiteral] 2 -# 316| getArgument: [IntegerLiteral] 3 -# 316| getStmt: [AssignExpr] ... = ... -# 316| getAnOperand/getLeftOperand: [LocalVariableAccess] a -# 316| getAnOperand/getRightOperand: [MethodCall] call to [] -# 316| getReceiver: [LocalVariableAccess] __synth__2 -# 316| getArgument: [IntegerLiteral] 0 -# 316| getStmt: [AssignExpr] ... = ... -# 316| getDesugared: [StmtSequence] ... -# 316| getStmt: [SetterMethodCall] call to []= -# 316| getReceiver: [LocalVariableAccess] __synth__1 -# 316| getArgument: [IntegerLiteral] 5 -# 316| getArgument: [AssignExpr] ... = ... -# 316| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 -# 316| getAnOperand/getRightOperand: [MethodCall] call to [] -# 316| getReceiver: [LocalVariableAccess] __synth__2 -# 316| getArgument: [RangeLiteral] _ .. _ -# 316| getBegin: [IntegerLiteral] 1 -# 316| getEnd: [IntegerLiteral] -1 -# 316| getStmt: [LocalVariableAccess] __synth__0__1 -# 316| getAnOperand/getLeftOperand: [MethodCall] call to [] -# 317| [AssignAddExpr] ... += ... +# 317| [AssignExpr] ... = ... # 317| getDesugared: [StmtSequence] ... -# 317| getStmt: [AssignExpr] ... = ... -# 317| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 -# 317| getAnOperand/getRightOperand: [SelfVariableAccess] self -# 317| getStmt: [AssignExpr] ... = ... -# 317| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__1 -# 317| getAnOperand/getRightOperand: [AddExpr] ... + ... -# 317| getAnOperand/getLeftOperand/getReceiver: [MethodCall] call to count -# 317| getReceiver: [LocalVariableAccess] __synth__0 -# 317| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 1 -# 317| getStmt: [SetterMethodCall] call to count= -# 317| getReceiver: [LocalVariableAccess] __synth__0 -# 317| getArgument: [LocalVariableAccess] __synth__1 -# 317| getStmt: [LocalVariableAccess] __synth__1 -# 318| [AssignAddExpr] ... += ... +# 317| getStmt: [SetterMethodCall] call to foo= +# 317| getReceiver: [SelfVariableAccess] self +# 317| getArgument: [AssignExpr] ... = ... +# 317| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 +# 317| getAnOperand/getRightOperand: [IntegerLiteral] 10 +# 317| getStmt: [LocalVariableAccess] __synth__0 +# 318| [AssignExpr] ... = ... # 318| getDesugared: [StmtSequence] ... -# 318| getStmt: [AssignExpr] ... = ... -# 318| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 -# 318| getAnOperand/getRightOperand: [MethodCall] call to foo -# 318| getReceiver: [SelfVariableAccess] self -# 318| getStmt: [AssignExpr] ... = ... -# 318| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__1 -# 318| getAnOperand/getRightOperand: [IntegerLiteral] 0 -# 318| getStmt: [AssignExpr] ... = ... -# 318| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__2 -# 318| getAnOperand/getRightOperand: [AddExpr] ... + ... -# 318| getAnOperand/getLeftOperand/getReceiver: [MethodCall] call to [] -# 318| getReceiver: [LocalVariableAccess] __synth__0 -# 318| getArgument: [LocalVariableAccess] __synth__1 -# 318| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 1 # 318| getStmt: [SetterMethodCall] call to []= -# 318| getReceiver: [LocalVariableAccess] __synth__0 -# 318| getArgument: [LocalVariableAccess] __synth__1 -# 318| getArgument: [LocalVariableAccess] __synth__2 -# 318| getStmt: [LocalVariableAccess] __synth__2 -# 319| [AssignMulExpr] ... *= ... +# 318| getReceiver: [MethodCall] call to foo +# 318| getReceiver: [SelfVariableAccess] self +# 318| getArgument: [IntegerLiteral] 0 +# 318| getArgument: [AssignExpr] ... = ... +# 318| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 +# 318| getAnOperand/getRightOperand: [IntegerLiteral] 10 +# 318| getStmt: [LocalVariableAccess] __synth__0 +# 319| [AssignExpr] ... = ... # 319| getDesugared: [StmtSequence] ... # 319| getStmt: [AssignExpr] ... = ... # 319| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 -# 319| getAnOperand/getRightOperand: [MethodCall] call to bar -# 319| getReceiver: [MethodCall] call to foo -# 319| getReceiver: [SelfVariableAccess] self +# 319| getAnOperand/getRightOperand: [SelfVariableAccess] self # 319| getStmt: [AssignExpr] ... = ... # 319| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__1 -# 319| getAnOperand/getRightOperand: [IntegerLiteral] 0 +# 319| getAnOperand/getRightOperand: [SelfVariableAccess] self # 319| getStmt: [AssignExpr] ... = ... # 319| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__2 -# 319| getAnOperand/getRightOperand: [MethodCall] call to baz -# 319| getReceiver: [MethodCall] call to foo -# 319| getReceiver: [SelfVariableAccess] self +# 319| getAnOperand/getRightOperand: [MethodCall] call to foo +# 319| getReceiver: [SelfVariableAccess] self # 319| getStmt: [AssignExpr] ... = ... # 319| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__3 -# 319| getAnOperand/getRightOperand: [AddExpr] ... + ... -# 319| getAnOperand/getLeftOperand/getReceiver: [MethodCall] call to boo -# 319| getReceiver: [MethodCall] call to foo -# 319| getReceiver: [SelfVariableAccess] self -# 319| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 1 +# 319| getAnOperand/getRightOperand: [SplatExpr] * ... +# 319| getAnOperand/getOperand/getReceiver: [ArrayLiteral] [...] +# 319| getDesugared: [MethodCall] call to [] +# 319| getReceiver: [ConstantReadAccess] Array +# 319| getArgument: [IntegerLiteral] 1 +# 319| getArgument: [IntegerLiteral] 2 +# 319| getArgument: [IntegerLiteral] 3 +# 319| getArgument: [IntegerLiteral] 4 # 319| getStmt: [AssignExpr] ... = ... -# 319| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__4 -# 319| getAnOperand/getRightOperand: [MulExpr] ... * ... -# 319| getAnOperand/getLeftOperand/getReceiver: [MethodCall] call to [] +# 319| getDesugared: [StmtSequence] ... +# 319| getStmt: [SetterMethodCall] call to foo= # 319| getReceiver: [LocalVariableAccess] __synth__0 -# 319| getArgument: [LocalVariableAccess] __synth__1 -# 319| getArgument: [LocalVariableAccess] __synth__2 -# 319| getArgument: [LocalVariableAccess] __synth__3 -# 319| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 2 -# 319| getStmt: [SetterMethodCall] call to []= -# 319| getReceiver: [LocalVariableAccess] __synth__0 -# 319| getArgument: [LocalVariableAccess] __synth__1 -# 319| getArgument: [LocalVariableAccess] __synth__2 -# 319| getArgument: [LocalVariableAccess] __synth__3 -# 319| getArgument: [LocalVariableAccess] __synth__4 -# 319| getStmt: [LocalVariableAccess] __synth__4 -# 339| [ForExpr] for ... in ... -# 339| getDesugared: [StmtSequence] ... -# 339| getStmt: [IfExpr] if ... -# 339| getCondition: [NotExpr] ! ... -# 339| getAnOperand/getOperand/getReceiver: [DefinedExpr] defined? ... -# 339| getAnOperand/getOperand/getReceiver: [LocalVariableAccess] x -# 339| getBranch/getThen: [AssignExpr] ... = ... -# 339| getAnOperand/getLeftOperand: [LocalVariableAccess] x -# 339| getAnOperand/getRightOperand: [NilLiteral] nil -# 339| getStmt: [IfExpr] if ... -# 339| getCondition: [NotExpr] ! ... -# 339| getAnOperand/getOperand/getReceiver: [DefinedExpr] defined? ... -# 339| getAnOperand/getOperand/getReceiver: [LocalVariableAccess] y -# 339| getBranch/getThen: [AssignExpr] ... = ... -# 339| getAnOperand/getLeftOperand: [LocalVariableAccess] y -# 339| getAnOperand/getRightOperand: [NilLiteral] nil -# 339| getStmt: [IfExpr] if ... -# 339| getCondition: [NotExpr] ! ... -# 339| getAnOperand/getOperand/getReceiver: [DefinedExpr] defined? ... -# 339| getAnOperand/getOperand/getReceiver: [LocalVariableAccess] z -# 339| getBranch/getThen: [AssignExpr] ... = ... -# 339| getAnOperand/getLeftOperand: [LocalVariableAccess] z -# 339| getAnOperand/getRightOperand: [NilLiteral] nil -# 339| getStmt: [MethodCall] call to each -# 339| getReceiver: [ArrayLiteral] [...] -# 339| getDesugared: [MethodCall] call to [] -# 339| getReceiver: [ConstantReadAccess] Array -# 339| getArgument: [ArrayLiteral] [...] -# 339| getDesugared: [MethodCall] call to [] -# 339| getReceiver: [ConstantReadAccess] Array -# 339| getArgument: [IntegerLiteral] 1 -# 339| getArgument: [IntegerLiteral] 2 -# 339| getArgument: [IntegerLiteral] 3 -# 339| getArgument: [ArrayLiteral] [...] -# 339| getDesugared: [MethodCall] call to [] -# 339| getReceiver: [ConstantReadAccess] Array -# 339| getArgument: [IntegerLiteral] 4 -# 339| getArgument: [IntegerLiteral] 5 -# 339| getArgument: [IntegerLiteral] 6 -# 339| getBlock: [BraceBlock] { ... } -# 339| getParameter: [SimpleParameter] __synth__0__1 -# 339| getDefiningAccess: [LocalVariableAccess] __synth__0__1 -# 339| getBody: [StmtSequence] ... -# 339| getStmt: [AssignExpr] ... = ... -# 339| getDesugared: [StmtSequence] ... -# 339| getStmt: [AssignExpr] ... = ... -# 339| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__3__1 -# 339| getAnOperand/getRightOperand: [SplatExpr] * ... -# 339| getAnOperand/getOperand/getReceiver: [LocalVariableAccess] __synth__0__1 -# 339| getStmt: [AssignExpr] ... = ... -# 339| getAnOperand/getLeftOperand: [LocalVariableAccess] x -# 339| getAnOperand/getRightOperand: [MethodCall] call to [] -# 339| getReceiver: [LocalVariableAccess] __synth__3__1 -# 339| getArgument: [IntegerLiteral] 0 -# 339| getStmt: [AssignExpr] ... = ... -# 339| getAnOperand/getLeftOperand: [LocalVariableAccess] y -# 339| getAnOperand/getRightOperand: [MethodCall] call to [] -# 339| getReceiver: [LocalVariableAccess] __synth__3__1 -# 339| getArgument: [IntegerLiteral] 1 -# 339| getStmt: [AssignExpr] ... = ... -# 339| getAnOperand/getLeftOperand: [LocalVariableAccess] z -# 339| getAnOperand/getRightOperand: [MethodCall] call to [] -# 339| getReceiver: [LocalVariableAccess] __synth__3__1 -# 339| getArgument: [IntegerLiteral] 2 -# 339| getAnOperand/getLeftOperand: [DestructuredLhsExpr] (..., ...) -# 340| getStmt: [MethodCall] call to foo -# 340| getReceiver: [SelfVariableAccess] self -# 340| getArgument: [LocalVariableAccess] x -# 340| getArgument: [LocalVariableAccess] y -# 340| getArgument: [LocalVariableAccess] z -# 361| [MethodCall] call to empty? -# 361| getDesugared: [StmtSequence] ... -# 361| getStmt: [AssignExpr] ... = ... -# 361| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 -# 361| getAnOperand/getRightOperand: [MethodCall] call to list -# 361| getReceiver: [SelfVariableAccess] self -# 361| getStmt: [IfExpr] if ... -# 361| getCondition: [MethodCall] call to == -# 361| getReceiver: [NilLiteral] nil -# 361| getArgument: [LocalVariableAccess] __synth__0__1 -# 361| getBranch/getThen: [NilLiteral] nil -# 361| getBranch/getElse: [MethodCall] call to empty? -# 361| getReceiver: [LocalVariableAccess] __synth__0__1 -# 363| [MethodCall] call to bar -# 363| getDesugared: [StmtSequence] ... -# 363| getStmt: [AssignExpr] ... = ... -# 363| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 -# 363| getAnOperand/getRightOperand: [MethodCall] call to foo -# 363| getReceiver: [SelfVariableAccess] self -# 363| getStmt: [IfExpr] if ... -# 363| getCondition: [MethodCall] call to == -# 363| getReceiver: [NilLiteral] nil -# 363| getArgument: [LocalVariableAccess] __synth__0__1 -# 363| getBranch/getThen: [NilLiteral] nil -# 363| getBranch/getElse: [MethodCall] call to bar -# 363| getReceiver: [LocalVariableAccess] __synth__0__1 -# 363| getArgument: [IntegerLiteral] 1 -# 363| getArgument: [IntegerLiteral] 2 -# 363| getBlock: [BraceBlock] { ... } -# 363| getParameter: [SimpleParameter] x -# 363| getDefiningAccess: [LocalVariableAccess] x -# 363| getBody: [StmtSequence] ... -# 363| getStmt: [LocalVariableAccess] x +# 319| getArgument: [AssignExpr] ... = ... +# 319| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 +# 319| getAnOperand/getRightOperand: [MethodCall] call to [] +# 319| getReceiver: [LocalVariableAccess] __synth__3 +# 319| getArgument: [IntegerLiteral] 0 +# 319| getStmt: [LocalVariableAccess] __synth__0__1 +# 319| getAnOperand/getLeftOperand: [MethodCall] call to foo +# 319| getStmt: [AssignExpr] ... = ... +# 319| getDesugared: [StmtSequence] ... +# 319| getStmt: [SetterMethodCall] call to bar= +# 319| getReceiver: [LocalVariableAccess] __synth__1 +# 319| getArgument: [AssignExpr] ... = ... +# 319| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 +# 319| getAnOperand/getRightOperand: [MethodCall] call to [] +# 319| getReceiver: [LocalVariableAccess] __synth__3 +# 319| getArgument: [RangeLiteral] _ .. _ +# 319| getBegin: [IntegerLiteral] 1 +# 319| getEnd: [IntegerLiteral] -2 +# 319| getStmt: [LocalVariableAccess] __synth__0__1 +# 319| getAnOperand/getLeftOperand: [MethodCall] call to bar +# 319| getStmt: [AssignExpr] ... = ... +# 319| getDesugared: [StmtSequence] ... +# 319| getStmt: [SetterMethodCall] call to []= +# 319| getReceiver: [LocalVariableAccess] __synth__2 +# 319| getArgument: [IntegerLiteral] 4 +# 319| getArgument: [AssignExpr] ... = ... +# 319| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 +# 319| getAnOperand/getRightOperand: [MethodCall] call to [] +# 319| getReceiver: [LocalVariableAccess] __synth__3 +# 319| getArgument: [IntegerLiteral] -1 +# 319| getStmt: [LocalVariableAccess] __synth__0__1 +# 319| getAnOperand/getLeftOperand: [MethodCall] call to [] +# 320| [AssignExpr] ... = ... +# 320| getDesugared: [StmtSequence] ... +# 320| getStmt: [AssignExpr] ... = ... +# 320| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__1 +# 320| getAnOperand/getRightOperand: [MethodCall] call to foo +# 320| getReceiver: [SelfVariableAccess] self +# 320| getStmt: [AssignExpr] ... = ... +# 320| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__2 +# 320| getAnOperand/getRightOperand: [SplatExpr] * ... +# 320| getAnOperand/getOperand/getReceiver: [ArrayLiteral] [...] +# 320| getDesugared: [MethodCall] call to [] +# 320| getReceiver: [ConstantReadAccess] Array +# 320| getArgument: [IntegerLiteral] 1 +# 320| getArgument: [IntegerLiteral] 2 +# 320| getArgument: [IntegerLiteral] 3 +# 320| getStmt: [AssignExpr] ... = ... +# 320| getAnOperand/getLeftOperand: [LocalVariableAccess] a +# 320| getAnOperand/getRightOperand: [MethodCall] call to [] +# 320| getReceiver: [LocalVariableAccess] __synth__2 +# 320| getArgument: [IntegerLiteral] 0 +# 320| getStmt: [AssignExpr] ... = ... +# 320| getDesugared: [StmtSequence] ... +# 320| getStmt: [SetterMethodCall] call to []= +# 320| getReceiver: [LocalVariableAccess] __synth__1 +# 320| getArgument: [IntegerLiteral] 5 +# 320| getArgument: [AssignExpr] ... = ... +# 320| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 +# 320| getAnOperand/getRightOperand: [MethodCall] call to [] +# 320| getReceiver: [LocalVariableAccess] __synth__2 +# 320| getArgument: [RangeLiteral] _ .. _ +# 320| getBegin: [IntegerLiteral] 1 +# 320| getEnd: [IntegerLiteral] -1 +# 320| getStmt: [LocalVariableAccess] __synth__0__1 +# 320| getAnOperand/getLeftOperand: [MethodCall] call to [] +# 321| [AssignAddExpr] ... += ... +# 321| getDesugared: [StmtSequence] ... +# 321| getStmt: [AssignExpr] ... = ... +# 321| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 +# 321| getAnOperand/getRightOperand: [SelfVariableAccess] self +# 321| getStmt: [AssignExpr] ... = ... +# 321| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__1 +# 321| getAnOperand/getRightOperand: [AddExpr] ... + ... +# 321| getAnOperand/getLeftOperand/getReceiver: [MethodCall] call to count +# 321| getReceiver: [LocalVariableAccess] __synth__0 +# 321| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 1 +# 321| getStmt: [SetterMethodCall] call to count= +# 321| getReceiver: [LocalVariableAccess] __synth__0 +# 321| getArgument: [LocalVariableAccess] __synth__1 +# 321| getStmt: [LocalVariableAccess] __synth__1 +# 322| [AssignAddExpr] ... += ... +# 322| getDesugared: [StmtSequence] ... +# 322| getStmt: [AssignExpr] ... = ... +# 322| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 +# 322| getAnOperand/getRightOperand: [MethodCall] call to foo +# 322| getReceiver: [SelfVariableAccess] self +# 322| getStmt: [AssignExpr] ... = ... +# 322| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__1 +# 322| getAnOperand/getRightOperand: [IntegerLiteral] 0 +# 322| getStmt: [AssignExpr] ... = ... +# 322| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__2 +# 322| getAnOperand/getRightOperand: [AddExpr] ... + ... +# 322| getAnOperand/getLeftOperand/getReceiver: [MethodCall] call to [] +# 322| getReceiver: [LocalVariableAccess] __synth__0 +# 322| getArgument: [LocalVariableAccess] __synth__1 +# 322| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 1 +# 322| getStmt: [SetterMethodCall] call to []= +# 322| getReceiver: [LocalVariableAccess] __synth__0 +# 322| getArgument: [LocalVariableAccess] __synth__1 +# 322| getArgument: [LocalVariableAccess] __synth__2 +# 322| getStmt: [LocalVariableAccess] __synth__2 +# 323| [AssignMulExpr] ... *= ... +# 323| getDesugared: [StmtSequence] ... +# 323| getStmt: [AssignExpr] ... = ... +# 323| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0 +# 323| getAnOperand/getRightOperand: [MethodCall] call to bar +# 323| getReceiver: [MethodCall] call to foo +# 323| getReceiver: [SelfVariableAccess] self +# 323| getStmt: [AssignExpr] ... = ... +# 323| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__1 +# 323| getAnOperand/getRightOperand: [IntegerLiteral] 0 +# 323| getStmt: [AssignExpr] ... = ... +# 323| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__2 +# 323| getAnOperand/getRightOperand: [MethodCall] call to baz +# 323| getReceiver: [MethodCall] call to foo +# 323| getReceiver: [SelfVariableAccess] self +# 323| getStmt: [AssignExpr] ... = ... +# 323| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__3 +# 323| getAnOperand/getRightOperand: [AddExpr] ... + ... +# 323| getAnOperand/getLeftOperand/getReceiver: [MethodCall] call to boo +# 323| getReceiver: [MethodCall] call to foo +# 323| getReceiver: [SelfVariableAccess] self +# 323| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 1 +# 323| getStmt: [AssignExpr] ... = ... +# 323| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__4 +# 323| getAnOperand/getRightOperand: [MulExpr] ... * ... +# 323| getAnOperand/getLeftOperand/getReceiver: [MethodCall] call to [] +# 323| getReceiver: [LocalVariableAccess] __synth__0 +# 323| getArgument: [LocalVariableAccess] __synth__1 +# 323| getArgument: [LocalVariableAccess] __synth__2 +# 323| getArgument: [LocalVariableAccess] __synth__3 +# 323| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 2 +# 323| getStmt: [SetterMethodCall] call to []= +# 323| getReceiver: [LocalVariableAccess] __synth__0 +# 323| getArgument: [LocalVariableAccess] __synth__1 +# 323| getArgument: [LocalVariableAccess] __synth__2 +# 323| getArgument: [LocalVariableAccess] __synth__3 +# 323| getArgument: [LocalVariableAccess] __synth__4 +# 323| getStmt: [LocalVariableAccess] __synth__4 +# 343| [ForExpr] for ... in ... +# 343| getDesugared: [StmtSequence] ... +# 343| getStmt: [IfExpr] if ... +# 343| getCondition: [NotExpr] ! ... +# 343| getAnOperand/getOperand/getReceiver: [DefinedExpr] defined? ... +# 343| getAnOperand/getOperand/getReceiver: [LocalVariableAccess] x +# 343| getBranch/getThen: [AssignExpr] ... = ... +# 343| getAnOperand/getLeftOperand: [LocalVariableAccess] x +# 343| getAnOperand/getRightOperand: [NilLiteral] nil +# 343| getStmt: [IfExpr] if ... +# 343| getCondition: [NotExpr] ! ... +# 343| getAnOperand/getOperand/getReceiver: [DefinedExpr] defined? ... +# 343| getAnOperand/getOperand/getReceiver: [LocalVariableAccess] y +# 343| getBranch/getThen: [AssignExpr] ... = ... +# 343| getAnOperand/getLeftOperand: [LocalVariableAccess] y +# 343| getAnOperand/getRightOperand: [NilLiteral] nil +# 343| getStmt: [IfExpr] if ... +# 343| getCondition: [NotExpr] ! ... +# 343| getAnOperand/getOperand/getReceiver: [DefinedExpr] defined? ... +# 343| getAnOperand/getOperand/getReceiver: [LocalVariableAccess] z +# 343| getBranch/getThen: [AssignExpr] ... = ... +# 343| getAnOperand/getLeftOperand: [LocalVariableAccess] z +# 343| getAnOperand/getRightOperand: [NilLiteral] nil +# 343| getStmt: [MethodCall] call to each +# 343| getReceiver: [ArrayLiteral] [...] +# 343| getDesugared: [MethodCall] call to [] +# 343| getReceiver: [ConstantReadAccess] Array +# 343| getArgument: [ArrayLiteral] [...] +# 343| getDesugared: [MethodCall] call to [] +# 343| getReceiver: [ConstantReadAccess] Array +# 343| getArgument: [IntegerLiteral] 1 +# 343| getArgument: [IntegerLiteral] 2 +# 343| getArgument: [IntegerLiteral] 3 +# 343| getArgument: [ArrayLiteral] [...] +# 343| getDesugared: [MethodCall] call to [] +# 343| getReceiver: [ConstantReadAccess] Array +# 343| getArgument: [IntegerLiteral] 4 +# 343| getArgument: [IntegerLiteral] 5 +# 343| getArgument: [IntegerLiteral] 6 +# 343| getBlock: [BraceBlock] { ... } +# 343| getParameter: [SimpleParameter] __synth__0__1 +# 343| getDefiningAccess: [LocalVariableAccess] __synth__0__1 +# 343| getBody: [StmtSequence] ... +# 343| getStmt: [AssignExpr] ... = ... +# 343| getDesugared: [StmtSequence] ... +# 343| getStmt: [AssignExpr] ... = ... +# 343| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__3__1 +# 343| getAnOperand/getRightOperand: [SplatExpr] * ... +# 343| getAnOperand/getOperand/getReceiver: [LocalVariableAccess] __synth__0__1 +# 343| getStmt: [AssignExpr] ... = ... +# 343| getAnOperand/getLeftOperand: [LocalVariableAccess] x +# 343| getAnOperand/getRightOperand: [MethodCall] call to [] +# 343| getReceiver: [LocalVariableAccess] __synth__3__1 +# 343| getArgument: [IntegerLiteral] 0 +# 343| getStmt: [AssignExpr] ... = ... +# 343| getAnOperand/getLeftOperand: [LocalVariableAccess] y +# 343| getAnOperand/getRightOperand: [MethodCall] call to [] +# 343| getReceiver: [LocalVariableAccess] __synth__3__1 +# 343| getArgument: [IntegerLiteral] 1 +# 343| getStmt: [AssignExpr] ... = ... +# 343| getAnOperand/getLeftOperand: [LocalVariableAccess] z +# 343| getAnOperand/getRightOperand: [MethodCall] call to [] +# 343| getReceiver: [LocalVariableAccess] __synth__3__1 +# 343| getArgument: [IntegerLiteral] 2 +# 343| getAnOperand/getLeftOperand: [DestructuredLhsExpr] (..., ...) +# 344| getStmt: [MethodCall] call to foo +# 344| getReceiver: [SelfVariableAccess] self +# 344| getArgument: [LocalVariableAccess] x +# 344| getArgument: [LocalVariableAccess] y +# 344| getArgument: [LocalVariableAccess] z +# 365| [MethodCall] call to empty? +# 365| getDesugared: [StmtSequence] ... +# 365| getStmt: [AssignExpr] ... = ... +# 365| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 +# 365| getAnOperand/getRightOperand: [MethodCall] call to list +# 365| getReceiver: [SelfVariableAccess] self +# 365| getStmt: [IfExpr] if ... +# 365| getCondition: [MethodCall] call to == +# 365| getReceiver: [NilLiteral] nil +# 365| getArgument: [LocalVariableAccess] __synth__0__1 +# 365| getBranch/getThen: [NilLiteral] nil +# 365| getBranch/getElse: [MethodCall] call to empty? +# 365| getReceiver: [LocalVariableAccess] __synth__0__1 +# 367| [MethodCall] call to bar +# 367| getDesugared: [StmtSequence] ... +# 367| getStmt: [AssignExpr] ... = ... +# 367| getAnOperand/getLeftOperand: [LocalVariableAccess] __synth__0__1 +# 367| getAnOperand/getRightOperand: [MethodCall] call to foo +# 367| getReceiver: [SelfVariableAccess] self +# 367| getStmt: [IfExpr] if ... +# 367| getCondition: [MethodCall] call to == +# 367| getReceiver: [NilLiteral] nil +# 367| getArgument: [LocalVariableAccess] __synth__0__1 +# 367| getBranch/getThen: [NilLiteral] nil +# 367| getBranch/getElse: [MethodCall] call to bar +# 367| getReceiver: [LocalVariableAccess] __synth__0__1 +# 367| getArgument: [IntegerLiteral] 1 +# 367| getArgument: [IntegerLiteral] 2 +# 367| getBlock: [BraceBlock] { ... } +# 367| getParameter: [SimpleParameter] x +# 367| getDefiningAccess: [LocalVariableAccess] x +# 367| getBody: [StmtSequence] ... +# 367| getStmt: [LocalVariableAccess] x control/cases.rb: # 90| [ArrayLiteral] %w(...) # 90| getDesugared: [MethodCall] call to [] diff --git a/ruby/ql/test/library-tests/ast/TreeSitter.expected b/ruby/ql/test/library-tests/ast/TreeSitter.expected index ab7937969d1..49ebf74a90d 100644 --- a/ruby/ql/test/library-tests/ast/TreeSitter.expected +++ b/ruby/ql/test/library-tests/ast/TreeSitter.expected @@ -715,627 +715,627 @@ calls/calls.rb: # 255| 1: [ReservedWord] :: # 255| 2: [Identifier] bar # 256| 3: [ReservedWord] end -# 259| 76: [RescueModifier] RescueModifier -# 259| 0: [Identifier] foo -# 259| 1: [ReservedWord] rescue -# 259| 2: [Identifier] bar -# 260| 77: [RescueModifier] RescueModifier -# 260| 0: [Call] Call -# 260| 0: [Constant] X -# 260| 1: [ReservedWord] :: -# 260| 2: [Identifier] foo -# 260| 1: [ReservedWord] rescue -# 260| 2: [Call] Call -# 260| 0: [Constant] X -# 260| 1: [ReservedWord] :: -# 260| 2: [Identifier] bar -# 263| 78: [Call] Call +# 263| 76: [RescueModifier] RescueModifier # 263| 0: [Identifier] foo -# 263| 1: [ArgumentList] ArgumentList -# 263| 0: [ReservedWord] ( -# 263| 1: [BlockArgument] BlockArgument -# 263| 0: [ReservedWord] & -# 263| 1: [Identifier] bar -# 263| 2: [ReservedWord] ) -# 264| 79: [Call] Call -# 264| 0: [Identifier] foo -# 264| 1: [ArgumentList] ArgumentList -# 264| 0: [ReservedWord] ( -# 264| 1: [BlockArgument] BlockArgument -# 264| 0: [ReservedWord] & -# 264| 1: [Call] Call -# 264| 0: [Constant] X -# 264| 1: [ReservedWord] :: -# 264| 2: [Identifier] bar -# 264| 2: [ReservedWord] ) -# 265| 80: [Call] Call -# 265| 0: [Identifier] foo -# 265| 1: [ArgumentList] ArgumentList -# 265| 0: [ReservedWord] ( -# 265| 1: [BlockArgument] BlockArgument -# 265| 0: [ReservedWord] & -# 265| 2: [ReservedWord] ) -# 267| 81: [Call] Call +# 263| 1: [ReservedWord] rescue +# 263| 2: [Identifier] bar +# 264| 77: [RescueModifier] RescueModifier +# 264| 0: [Call] Call +# 264| 0: [Constant] X +# 264| 1: [ReservedWord] :: +# 264| 2: [Identifier] foo +# 264| 1: [ReservedWord] rescue +# 264| 2: [Call] Call +# 264| 0: [Constant] X +# 264| 1: [ReservedWord] :: +# 264| 2: [Identifier] bar +# 267| 78: [Call] Call # 267| 0: [Identifier] foo # 267| 1: [ArgumentList] ArgumentList # 267| 0: [ReservedWord] ( -# 267| 1: [SplatArgument] SplatArgument -# 267| 0: [ReservedWord] * +# 267| 1: [BlockArgument] BlockArgument +# 267| 0: [ReservedWord] & # 267| 1: [Identifier] bar # 267| 2: [ReservedWord] ) -# 268| 82: [Call] Call +# 268| 79: [Call] Call # 268| 0: [Identifier] foo # 268| 1: [ArgumentList] ArgumentList # 268| 0: [ReservedWord] ( -# 268| 1: [SplatArgument] SplatArgument -# 268| 0: [ReservedWord] * +# 268| 1: [BlockArgument] BlockArgument +# 268| 0: [ReservedWord] & # 268| 1: [Call] Call # 268| 0: [Constant] X # 268| 1: [ReservedWord] :: # 268| 2: [Identifier] bar # 268| 2: [ReservedWord] ) -# 269| 83: [Call] Call +# 269| 80: [Call] Call # 269| 0: [Identifier] foo # 269| 1: [ArgumentList] ArgumentList # 269| 0: [ReservedWord] ( -# 269| 1: [SplatArgument] SplatArgument -# 269| 0: [ReservedWord] * +# 269| 1: [BlockArgument] BlockArgument +# 269| 0: [ReservedWord] & # 269| 2: [ReservedWord] ) -# 272| 84: [Call] Call +# 271| 81: [Call] Call +# 271| 0: [Identifier] foo +# 271| 1: [ArgumentList] ArgumentList +# 271| 0: [ReservedWord] ( +# 271| 1: [SplatArgument] SplatArgument +# 271| 0: [ReservedWord] * +# 271| 1: [Identifier] bar +# 271| 2: [ReservedWord] ) +# 272| 82: [Call] Call # 272| 0: [Identifier] foo # 272| 1: [ArgumentList] ArgumentList # 272| 0: [ReservedWord] ( -# 272| 1: [HashSplatArgument] HashSplatArgument -# 272| 0: [ReservedWord] ** -# 272| 1: [Identifier] bar +# 272| 1: [SplatArgument] SplatArgument +# 272| 0: [ReservedWord] * +# 272| 1: [Call] Call +# 272| 0: [Constant] X +# 272| 1: [ReservedWord] :: +# 272| 2: [Identifier] bar # 272| 2: [ReservedWord] ) -# 273| 85: [Call] Call +# 273| 83: [Call] Call # 273| 0: [Identifier] foo # 273| 1: [ArgumentList] ArgumentList # 273| 0: [ReservedWord] ( -# 273| 1: [HashSplatArgument] HashSplatArgument -# 273| 0: [ReservedWord] ** -# 273| 1: [Call] Call -# 273| 0: [Constant] X -# 273| 1: [ReservedWord] :: -# 273| 2: [Identifier] bar +# 273| 1: [SplatArgument] SplatArgument +# 273| 0: [ReservedWord] * # 273| 2: [ReservedWord] ) -# 274| 86: [Call] Call -# 274| 0: [Identifier] foo -# 274| 1: [ArgumentList] ArgumentList -# 274| 0: [ReservedWord] ( -# 274| 1: [HashSplatArgument] HashSplatArgument -# 274| 0: [ReservedWord] ** -# 274| 2: [ReservedWord] ) -# 277| 87: [Call] Call +# 276| 84: [Call] Call +# 276| 0: [Identifier] foo +# 276| 1: [ArgumentList] ArgumentList +# 276| 0: [ReservedWord] ( +# 276| 1: [HashSplatArgument] HashSplatArgument +# 276| 0: [ReservedWord] ** +# 276| 1: [Identifier] bar +# 276| 2: [ReservedWord] ) +# 277| 85: [Call] Call # 277| 0: [Identifier] foo # 277| 1: [ArgumentList] ArgumentList # 277| 0: [ReservedWord] ( -# 277| 1: [Pair] Pair -# 277| 0: [HashKeySymbol] blah -# 277| 1: [ReservedWord] : -# 277| 2: [Identifier] bar +# 277| 1: [HashSplatArgument] HashSplatArgument +# 277| 0: [ReservedWord] ** +# 277| 1: [Call] Call +# 277| 0: [Constant] X +# 277| 1: [ReservedWord] :: +# 277| 2: [Identifier] bar # 277| 2: [ReservedWord] ) -# 278| 88: [Call] Call +# 278| 86: [Call] Call # 278| 0: [Identifier] foo # 278| 1: [ArgumentList] ArgumentList # 278| 0: [ReservedWord] ( -# 278| 1: [Pair] Pair -# 278| 0: [HashKeySymbol] blah -# 278| 1: [ReservedWord] : -# 278| 2: [Call] Call -# 278| 0: [Constant] X -# 278| 1: [ReservedWord] :: -# 278| 2: [Identifier] bar +# 278| 1: [HashSplatArgument] HashSplatArgument +# 278| 0: [ReservedWord] ** # 278| 2: [ReservedWord] ) -# 283| 89: [Class] Class -# 283| 0: [ReservedWord] class -# 283| 1: [Constant] MyClass -# 284| 2: [BodyStatement] BodyStatement -# 284| 0: [Method] Method -# 284| 0: [ReservedWord] def -# 284| 1: [Identifier] my_method -# 285| 2: [BodyStatement] BodyStatement -# 285| 0: [Super] super -# 286| 1: [Call] Call -# 286| 0: [Super] super -# 286| 1: [ArgumentList] ArgumentList -# 286| 0: [ReservedWord] ( -# 286| 1: [ReservedWord] ) -# 287| 2: [Call] Call -# 287| 0: [Super] super -# 287| 1: [ArgumentList] ArgumentList -# 287| 0: [String] String -# 287| 0: [ReservedWord] ' -# 287| 1: [StringContent] blah -# 287| 2: [ReservedWord] ' -# 288| 3: [Call] Call -# 288| 0: [Super] super -# 288| 1: [ArgumentList] ArgumentList -# 288| 0: [Integer] 1 -# 288| 1: [ReservedWord] , -# 288| 2: [Integer] 2 -# 288| 3: [ReservedWord] , -# 288| 4: [Integer] 3 -# 289| 4: [Call] Call -# 289| 0: [Super] super -# 289| 1: [Block] Block -# 289| 0: [ReservedWord] { -# 289| 1: [BlockParameters] BlockParameters -# 289| 0: [ReservedWord] | -# 289| 1: [Identifier] x -# 289| 2: [ReservedWord] | -# 289| 2: [BlockBody] BlockBody -# 289| 0: [Binary] Binary -# 289| 0: [Identifier] x -# 289| 1: [ReservedWord] + -# 289| 2: [Integer] 1 -# 289| 3: [ReservedWord] } -# 290| 5: [Call] Call +# 281| 87: [Call] Call +# 281| 0: [Identifier] foo +# 281| 1: [ArgumentList] ArgumentList +# 281| 0: [ReservedWord] ( +# 281| 1: [Pair] Pair +# 281| 0: [HashKeySymbol] blah +# 281| 1: [ReservedWord] : +# 281| 2: [Identifier] bar +# 281| 2: [ReservedWord] ) +# 282| 88: [Call] Call +# 282| 0: [Identifier] foo +# 282| 1: [ArgumentList] ArgumentList +# 282| 0: [ReservedWord] ( +# 282| 1: [Pair] Pair +# 282| 0: [HashKeySymbol] blah +# 282| 1: [ReservedWord] : +# 282| 2: [Call] Call +# 282| 0: [Constant] X +# 282| 1: [ReservedWord] :: +# 282| 2: [Identifier] bar +# 282| 2: [ReservedWord] ) +# 287| 89: [Class] Class +# 287| 0: [ReservedWord] class +# 287| 1: [Constant] MyClass +# 288| 2: [BodyStatement] BodyStatement +# 288| 0: [Method] Method +# 288| 0: [ReservedWord] def +# 288| 1: [Identifier] my_method +# 289| 2: [BodyStatement] BodyStatement +# 289| 0: [Super] super +# 290| 1: [Call] Call # 290| 0: [Super] super -# 290| 1: [DoBlock] DoBlock -# 290| 0: [ReservedWord] do -# 290| 1: [BlockParameters] BlockParameters -# 290| 0: [ReservedWord] | -# 290| 1: [Identifier] x -# 290| 2: [ReservedWord] | -# 290| 2: [BodyStatement] BodyStatement -# 290| 0: [Binary] Binary -# 290| 0: [Identifier] x -# 290| 1: [ReservedWord] * -# 290| 2: [Integer] 2 -# 290| 3: [ReservedWord] end -# 291| 6: [Call] Call +# 290| 1: [ArgumentList] ArgumentList +# 290| 0: [ReservedWord] ( +# 290| 1: [ReservedWord] ) +# 291| 2: [Call] Call # 291| 0: [Super] super # 291| 1: [ArgumentList] ArgumentList -# 291| 0: [Integer] 4 -# 291| 1: [ReservedWord] , -# 291| 2: [Integer] 5 -# 291| 2: [Block] Block -# 291| 0: [ReservedWord] { -# 291| 1: [BlockParameters] BlockParameters -# 291| 0: [ReservedWord] | -# 291| 1: [Identifier] x -# 291| 2: [ReservedWord] | -# 291| 2: [BlockBody] BlockBody -# 291| 0: [Binary] Binary -# 291| 0: [Identifier] x -# 291| 1: [ReservedWord] + -# 291| 2: [Integer] 100 -# 291| 3: [ReservedWord] } -# 292| 7: [Call] Call +# 291| 0: [String] String +# 291| 0: [ReservedWord] ' +# 291| 1: [StringContent] blah +# 291| 2: [ReservedWord] ' +# 292| 3: [Call] Call # 292| 0: [Super] super # 292| 1: [ArgumentList] ArgumentList -# 292| 0: [Integer] 6 +# 292| 0: [Integer] 1 # 292| 1: [ReservedWord] , -# 292| 2: [Integer] 7 -# 292| 2: [DoBlock] DoBlock -# 292| 0: [ReservedWord] do -# 292| 1: [BlockParameters] BlockParameters -# 292| 0: [ReservedWord] | -# 292| 1: [Identifier] x -# 292| 2: [ReservedWord] | -# 292| 2: [BodyStatement] BodyStatement -# 292| 0: [Binary] Binary -# 292| 0: [Identifier] x -# 292| 1: [ReservedWord] + -# 292| 2: [Integer] 200 -# 292| 3: [ReservedWord] end -# 293| 3: [ReservedWord] end -# 294| 3: [ReservedWord] end -# 300| 90: [Class] Class -# 300| 0: [ReservedWord] class -# 300| 1: [Constant] AnotherClass -# 301| 2: [BodyStatement] BodyStatement -# 301| 0: [Method] Method -# 301| 0: [ReservedWord] def -# 301| 1: [Identifier] another_method -# 302| 2: [BodyStatement] BodyStatement -# 302| 0: [Call] Call -# 302| 0: [Identifier] foo -# 302| 1: [ReservedWord] . -# 302| 2: [Identifier] super -# 303| 1: [Call] Call -# 303| 0: [Self] self -# 303| 1: [ReservedWord] . -# 303| 2: [Identifier] super -# 304| 2: [Call] Call -# 304| 0: [Super] super -# 304| 1: [ReservedWord] . -# 304| 2: [Identifier] super -# 305| 3: [ReservedWord] end -# 306| 3: [ReservedWord] end -# 309| 91: [Call] Call -# 309| 0: [Identifier] foo -# 309| 1: [ReservedWord] . -# 309| 2: [ArgumentList] ArgumentList -# 309| 0: [ReservedWord] ( -# 309| 1: [ReservedWord] ) -# 310| 92: [Call] Call -# 310| 0: [Identifier] foo -# 310| 1: [ReservedWord] . -# 310| 2: [ArgumentList] ArgumentList -# 310| 0: [ReservedWord] ( -# 310| 1: [Integer] 1 -# 310| 2: [ReservedWord] ) -# 313| 93: [Assignment] Assignment -# 313| 0: [Call] Call -# 313| 0: [Self] self -# 313| 1: [ReservedWord] . -# 313| 2: [Identifier] foo -# 313| 1: [ReservedWord] = -# 313| 2: [Integer] 10 -# 314| 94: [Assignment] Assignment -# 314| 0: [ElementReference] ElementReference -# 314| 0: [Identifier] foo -# 314| 1: [ReservedWord] [ -# 314| 2: [Integer] 0 -# 314| 3: [ReservedWord] ] -# 314| 1: [ReservedWord] = -# 314| 2: [Integer] 10 -# 315| 95: [Assignment] Assignment -# 315| 0: [LeftAssignmentList] LeftAssignmentList -# 315| 0: [Call] Call -# 315| 0: [Self] self -# 315| 1: [ReservedWord] . -# 315| 2: [Identifier] foo -# 315| 1: [ReservedWord] , -# 315| 2: [RestAssignment] RestAssignment -# 315| 0: [ReservedWord] * -# 315| 1: [Call] Call -# 315| 0: [Self] self -# 315| 1: [ReservedWord] . -# 315| 2: [Identifier] bar -# 315| 3: [ReservedWord] , -# 315| 4: [ElementReference] ElementReference -# 315| 0: [Identifier] foo -# 315| 1: [ReservedWord] [ -# 315| 2: [Integer] 4 -# 315| 3: [ReservedWord] ] -# 315| 1: [ReservedWord] = -# 315| 2: [Array] Array -# 315| 0: [ReservedWord] [ -# 315| 1: [Integer] 1 -# 315| 2: [ReservedWord] , -# 315| 3: [Integer] 2 -# 315| 4: [ReservedWord] , -# 315| 5: [Integer] 3 -# 315| 6: [ReservedWord] , -# 315| 7: [Integer] 4 -# 315| 8: [ReservedWord] ] -# 316| 96: [Assignment] Assignment -# 316| 0: [LeftAssignmentList] LeftAssignmentList -# 316| 0: [Identifier] a -# 316| 1: [ReservedWord] , -# 316| 2: [RestAssignment] RestAssignment -# 316| 0: [ReservedWord] * -# 316| 1: [ElementReference] ElementReference -# 316| 0: [Identifier] foo -# 316| 1: [ReservedWord] [ -# 316| 2: [Integer] 5 -# 316| 3: [ReservedWord] ] -# 316| 1: [ReservedWord] = -# 316| 2: [Array] Array -# 316| 0: [ReservedWord] [ -# 316| 1: [Integer] 1 -# 316| 2: [ReservedWord] , -# 316| 3: [Integer] 2 -# 316| 4: [ReservedWord] , -# 316| 5: [Integer] 3 -# 316| 6: [ReservedWord] ] -# 317| 97: [OperatorAssignment] OperatorAssignment +# 292| 2: [Integer] 2 +# 292| 3: [ReservedWord] , +# 292| 4: [Integer] 3 +# 293| 4: [Call] Call +# 293| 0: [Super] super +# 293| 1: [Block] Block +# 293| 0: [ReservedWord] { +# 293| 1: [BlockParameters] BlockParameters +# 293| 0: [ReservedWord] | +# 293| 1: [Identifier] x +# 293| 2: [ReservedWord] | +# 293| 2: [BlockBody] BlockBody +# 293| 0: [Binary] Binary +# 293| 0: [Identifier] x +# 293| 1: [ReservedWord] + +# 293| 2: [Integer] 1 +# 293| 3: [ReservedWord] } +# 294| 5: [Call] Call +# 294| 0: [Super] super +# 294| 1: [DoBlock] DoBlock +# 294| 0: [ReservedWord] do +# 294| 1: [BlockParameters] BlockParameters +# 294| 0: [ReservedWord] | +# 294| 1: [Identifier] x +# 294| 2: [ReservedWord] | +# 294| 2: [BodyStatement] BodyStatement +# 294| 0: [Binary] Binary +# 294| 0: [Identifier] x +# 294| 1: [ReservedWord] * +# 294| 2: [Integer] 2 +# 294| 3: [ReservedWord] end +# 295| 6: [Call] Call +# 295| 0: [Super] super +# 295| 1: [ArgumentList] ArgumentList +# 295| 0: [Integer] 4 +# 295| 1: [ReservedWord] , +# 295| 2: [Integer] 5 +# 295| 2: [Block] Block +# 295| 0: [ReservedWord] { +# 295| 1: [BlockParameters] BlockParameters +# 295| 0: [ReservedWord] | +# 295| 1: [Identifier] x +# 295| 2: [ReservedWord] | +# 295| 2: [BlockBody] BlockBody +# 295| 0: [Binary] Binary +# 295| 0: [Identifier] x +# 295| 1: [ReservedWord] + +# 295| 2: [Integer] 100 +# 295| 3: [ReservedWord] } +# 296| 7: [Call] Call +# 296| 0: [Super] super +# 296| 1: [ArgumentList] ArgumentList +# 296| 0: [Integer] 6 +# 296| 1: [ReservedWord] , +# 296| 2: [Integer] 7 +# 296| 2: [DoBlock] DoBlock +# 296| 0: [ReservedWord] do +# 296| 1: [BlockParameters] BlockParameters +# 296| 0: [ReservedWord] | +# 296| 1: [Identifier] x +# 296| 2: [ReservedWord] | +# 296| 2: [BodyStatement] BodyStatement +# 296| 0: [Binary] Binary +# 296| 0: [Identifier] x +# 296| 1: [ReservedWord] + +# 296| 2: [Integer] 200 +# 296| 3: [ReservedWord] end +# 297| 3: [ReservedWord] end +# 298| 3: [ReservedWord] end +# 304| 90: [Class] Class +# 304| 0: [ReservedWord] class +# 304| 1: [Constant] AnotherClass +# 305| 2: [BodyStatement] BodyStatement +# 305| 0: [Method] Method +# 305| 0: [ReservedWord] def +# 305| 1: [Identifier] another_method +# 306| 2: [BodyStatement] BodyStatement +# 306| 0: [Call] Call +# 306| 0: [Identifier] foo +# 306| 1: [ReservedWord] . +# 306| 2: [Identifier] super +# 307| 1: [Call] Call +# 307| 0: [Self] self +# 307| 1: [ReservedWord] . +# 307| 2: [Identifier] super +# 308| 2: [Call] Call +# 308| 0: [Super] super +# 308| 1: [ReservedWord] . +# 308| 2: [Identifier] super +# 309| 3: [ReservedWord] end +# 310| 3: [ReservedWord] end +# 313| 91: [Call] Call +# 313| 0: [Identifier] foo +# 313| 1: [ReservedWord] . +# 313| 2: [ArgumentList] ArgumentList +# 313| 0: [ReservedWord] ( +# 313| 1: [ReservedWord] ) +# 314| 92: [Call] Call +# 314| 0: [Identifier] foo +# 314| 1: [ReservedWord] . +# 314| 2: [ArgumentList] ArgumentList +# 314| 0: [ReservedWord] ( +# 314| 1: [Integer] 1 +# 314| 2: [ReservedWord] ) +# 317| 93: [Assignment] Assignment # 317| 0: [Call] Call # 317| 0: [Self] self # 317| 1: [ReservedWord] . -# 317| 2: [Identifier] count -# 317| 1: [ReservedWord] += -# 317| 2: [Integer] 1 -# 318| 98: [OperatorAssignment] OperatorAssignment +# 317| 2: [Identifier] foo +# 317| 1: [ReservedWord] = +# 317| 2: [Integer] 10 +# 318| 94: [Assignment] Assignment # 318| 0: [ElementReference] ElementReference # 318| 0: [Identifier] foo # 318| 1: [ReservedWord] [ # 318| 2: [Integer] 0 # 318| 3: [ReservedWord] ] -# 318| 1: [ReservedWord] += -# 318| 2: [Integer] 1 -# 319| 99: [OperatorAssignment] OperatorAssignment -# 319| 0: [ElementReference] ElementReference +# 318| 1: [ReservedWord] = +# 318| 2: [Integer] 10 +# 319| 95: [Assignment] Assignment +# 319| 0: [LeftAssignmentList] LeftAssignmentList # 319| 0: [Call] Call -# 319| 0: [Identifier] foo +# 319| 0: [Self] self # 319| 1: [ReservedWord] . -# 319| 2: [Identifier] bar -# 319| 1: [ReservedWord] [ -# 319| 2: [Integer] 0 -# 319| 3: [ReservedWord] , -# 319| 4: [Call] Call -# 319| 0: [Identifier] foo -# 319| 1: [ReservedWord] . -# 319| 2: [Identifier] baz -# 319| 5: [ReservedWord] , -# 319| 6: [Binary] Binary -# 319| 0: [Call] Call -# 319| 0: [Identifier] foo +# 319| 2: [Identifier] foo +# 319| 1: [ReservedWord] , +# 319| 2: [RestAssignment] RestAssignment +# 319| 0: [ReservedWord] * +# 319| 1: [Call] Call +# 319| 0: [Self] self # 319| 1: [ReservedWord] . -# 319| 2: [Identifier] boo -# 319| 1: [ReservedWord] + -# 319| 2: [Integer] 1 -# 319| 7: [ReservedWord] ] -# 319| 1: [ReservedWord] *= -# 319| 2: [Integer] 2 -# 322| 100: [Method] Method -# 322| 0: [ReservedWord] def -# 322| 1: [Identifier] foo -# 322| 2: [ReservedWord] = -# 322| 3: [Identifier] bar -# 323| 101: [Method] Method -# 323| 0: [ReservedWord] def -# 323| 1: [Identifier] foo -# 323| 2: [MethodParameters] MethodParameters -# 323| 0: [ReservedWord] ( -# 323| 1: [ReservedWord] ) -# 323| 3: [ReservedWord] = -# 323| 4: [Identifier] bar -# 324| 102: [Method] Method -# 324| 0: [ReservedWord] def -# 324| 1: [Identifier] foo -# 324| 2: [MethodParameters] MethodParameters -# 324| 0: [ReservedWord] ( -# 324| 1: [Identifier] x -# 324| 2: [ReservedWord] ) -# 324| 3: [ReservedWord] = -# 324| 4: [Identifier] bar -# 325| 103: [SingletonMethod] SingletonMethod -# 325| 0: [ReservedWord] def -# 325| 1: [Constant] Object -# 325| 2: [ReservedWord] . -# 325| 3: [Identifier] foo -# 325| 4: [ReservedWord] = -# 325| 5: [Identifier] bar -# 326| 104: [SingletonMethod] SingletonMethod +# 319| 2: [Identifier] bar +# 319| 3: [ReservedWord] , +# 319| 4: [ElementReference] ElementReference +# 319| 0: [Identifier] foo +# 319| 1: [ReservedWord] [ +# 319| 2: [Integer] 4 +# 319| 3: [ReservedWord] ] +# 319| 1: [ReservedWord] = +# 319| 2: [Array] Array +# 319| 0: [ReservedWord] [ +# 319| 1: [Integer] 1 +# 319| 2: [ReservedWord] , +# 319| 3: [Integer] 2 +# 319| 4: [ReservedWord] , +# 319| 5: [Integer] 3 +# 319| 6: [ReservedWord] , +# 319| 7: [Integer] 4 +# 319| 8: [ReservedWord] ] +# 320| 96: [Assignment] Assignment +# 320| 0: [LeftAssignmentList] LeftAssignmentList +# 320| 0: [Identifier] a +# 320| 1: [ReservedWord] , +# 320| 2: [RestAssignment] RestAssignment +# 320| 0: [ReservedWord] * +# 320| 1: [ElementReference] ElementReference +# 320| 0: [Identifier] foo +# 320| 1: [ReservedWord] [ +# 320| 2: [Integer] 5 +# 320| 3: [ReservedWord] ] +# 320| 1: [ReservedWord] = +# 320| 2: [Array] Array +# 320| 0: [ReservedWord] [ +# 320| 1: [Integer] 1 +# 320| 2: [ReservedWord] , +# 320| 3: [Integer] 2 +# 320| 4: [ReservedWord] , +# 320| 5: [Integer] 3 +# 320| 6: [ReservedWord] ] +# 321| 97: [OperatorAssignment] OperatorAssignment +# 321| 0: [Call] Call +# 321| 0: [Self] self +# 321| 1: [ReservedWord] . +# 321| 2: [Identifier] count +# 321| 1: [ReservedWord] += +# 321| 2: [Integer] 1 +# 322| 98: [OperatorAssignment] OperatorAssignment +# 322| 0: [ElementReference] ElementReference +# 322| 0: [Identifier] foo +# 322| 1: [ReservedWord] [ +# 322| 2: [Integer] 0 +# 322| 3: [ReservedWord] ] +# 322| 1: [ReservedWord] += +# 322| 2: [Integer] 1 +# 323| 99: [OperatorAssignment] OperatorAssignment +# 323| 0: [ElementReference] ElementReference +# 323| 0: [Call] Call +# 323| 0: [Identifier] foo +# 323| 1: [ReservedWord] . +# 323| 2: [Identifier] bar +# 323| 1: [ReservedWord] [ +# 323| 2: [Integer] 0 +# 323| 3: [ReservedWord] , +# 323| 4: [Call] Call +# 323| 0: [Identifier] foo +# 323| 1: [ReservedWord] . +# 323| 2: [Identifier] baz +# 323| 5: [ReservedWord] , +# 323| 6: [Binary] Binary +# 323| 0: [Call] Call +# 323| 0: [Identifier] foo +# 323| 1: [ReservedWord] . +# 323| 2: [Identifier] boo +# 323| 1: [ReservedWord] + +# 323| 2: [Integer] 1 +# 323| 7: [ReservedWord] ] +# 323| 1: [ReservedWord] *= +# 323| 2: [Integer] 2 +# 326| 100: [Method] Method # 326| 0: [ReservedWord] def -# 326| 1: [Constant] Object -# 326| 2: [ReservedWord] . -# 326| 3: [Identifier] foo -# 326| 4: [MethodParameters] MethodParameters -# 326| 0: [ReservedWord] ( -# 326| 1: [Identifier] x -# 326| 2: [ReservedWord] ) -# 326| 5: [ReservedWord] = -# 326| 6: [Identifier] bar -# 327| 105: [Method] Method +# 326| 1: [Identifier] foo +# 326| 2: [ReservedWord] = +# 326| 3: [Identifier] bar +# 327| 101: [Method] Method # 327| 0: [ReservedWord] def # 327| 1: [Identifier] foo # 327| 2: [MethodParameters] MethodParameters # 327| 0: [ReservedWord] ( # 327| 1: [ReservedWord] ) # 327| 3: [ReservedWord] = -# 327| 4: [RescueModifier] RescueModifier -# 327| 0: [Identifier] bar -# 327| 1: [ReservedWord] rescue -# 327| 2: [ParenthesizedStatements] ParenthesizedStatements -# 327| 0: [ReservedWord] ( -# 327| 1: [Call] Call -# 327| 0: [Identifier] print -# 327| 1: [ArgumentList] ArgumentList -# 327| 0: [String] String -# 327| 0: [ReservedWord] " -# 327| 1: [StringContent] error -# 327| 2: [ReservedWord] " -# 327| 2: [ReservedWord] ) -# 330| 106: [Method] Method +# 327| 4: [Identifier] bar +# 328| 102: [Method] Method +# 328| 0: [ReservedWord] def +# 328| 1: [Identifier] foo +# 328| 2: [MethodParameters] MethodParameters +# 328| 0: [ReservedWord] ( +# 328| 1: [Identifier] x +# 328| 2: [ReservedWord] ) +# 328| 3: [ReservedWord] = +# 328| 4: [Identifier] bar +# 329| 103: [SingletonMethod] SingletonMethod +# 329| 0: [ReservedWord] def +# 329| 1: [Constant] Object +# 329| 2: [ReservedWord] . +# 329| 3: [Identifier] foo +# 329| 4: [ReservedWord] = +# 329| 5: [Identifier] bar +# 330| 104: [SingletonMethod] SingletonMethod # 330| 0: [ReservedWord] def -# 330| 1: [Identifier] foo -# 330| 2: [MethodParameters] MethodParameters +# 330| 1: [Constant] Object +# 330| 2: [ReservedWord] . +# 330| 3: [Identifier] foo +# 330| 4: [MethodParameters] MethodParameters # 330| 0: [ReservedWord] ( -# 330| 1: [ForwardParameter] ... -# 330| 0: [ReservedWord] ... +# 330| 1: [Identifier] x # 330| 2: [ReservedWord] ) -# 331| 3: [BodyStatement] BodyStatement -# 331| 0: [Call] Call -# 331| 0: [Super] super -# 331| 1: [ArgumentList] ArgumentList -# 331| 0: [ReservedWord] ( -# 331| 1: [ForwardArgument] ... -# 331| 0: [ReservedWord] ... -# 331| 2: [ReservedWord] ) -# 332| 4: [ReservedWord] end -# 334| 107: [Method] Method +# 330| 5: [ReservedWord] = +# 330| 6: [Identifier] bar +# 331| 105: [Method] Method +# 331| 0: [ReservedWord] def +# 331| 1: [Identifier] foo +# 331| 2: [MethodParameters] MethodParameters +# 331| 0: [ReservedWord] ( +# 331| 1: [ReservedWord] ) +# 331| 3: [ReservedWord] = +# 331| 4: [RescueModifier] RescueModifier +# 331| 0: [Identifier] bar +# 331| 1: [ReservedWord] rescue +# 331| 2: [ParenthesizedStatements] ParenthesizedStatements +# 331| 0: [ReservedWord] ( +# 331| 1: [Call] Call +# 331| 0: [Identifier] print +# 331| 1: [ArgumentList] ArgumentList +# 331| 0: [String] String +# 331| 0: [ReservedWord] " +# 331| 1: [StringContent] error +# 331| 2: [ReservedWord] " +# 331| 2: [ReservedWord] ) +# 334| 106: [Method] Method # 334| 0: [ReservedWord] def # 334| 1: [Identifier] foo # 334| 2: [MethodParameters] MethodParameters # 334| 0: [ReservedWord] ( -# 334| 1: [Identifier] a -# 334| 2: [ReservedWord] , -# 334| 3: [Identifier] b -# 334| 4: [ReservedWord] , -# 334| 5: [ForwardParameter] ... +# 334| 1: [ForwardParameter] ... # 334| 0: [ReservedWord] ... -# 334| 6: [ReservedWord] ) +# 334| 2: [ReservedWord] ) # 335| 3: [BodyStatement] BodyStatement # 335| 0: [Call] Call -# 335| 0: [Identifier] bar +# 335| 0: [Super] super # 335| 1: [ArgumentList] ArgumentList # 335| 0: [ReservedWord] ( -# 335| 1: [Identifier] b -# 335| 2: [ReservedWord] , -# 335| 3: [ForwardArgument] ... +# 335| 1: [ForwardArgument] ... # 335| 0: [ReservedWord] ... -# 335| 4: [ReservedWord] ) +# 335| 2: [ReservedWord] ) # 336| 4: [ReservedWord] end -# 339| 108: [For] For -# 339| 0: [ReservedWord] for -# 339| 1: [LeftAssignmentList] LeftAssignmentList -# 339| 0: [Identifier] x -# 339| 1: [ReservedWord] , -# 339| 2: [Identifier] y -# 339| 3: [ReservedWord] , -# 339| 4: [Identifier] z -# 339| 2: [In] In -# 339| 0: [ReservedWord] in -# 339| 1: [Array] Array -# 339| 0: [ReservedWord] [ -# 339| 1: [Array] Array -# 339| 0: [ReservedWord] [ -# 339| 1: [Integer] 1 +# 338| 107: [Method] Method +# 338| 0: [ReservedWord] def +# 338| 1: [Identifier] foo +# 338| 2: [MethodParameters] MethodParameters +# 338| 0: [ReservedWord] ( +# 338| 1: [Identifier] a +# 338| 2: [ReservedWord] , +# 338| 3: [Identifier] b +# 338| 4: [ReservedWord] , +# 338| 5: [ForwardParameter] ... +# 338| 0: [ReservedWord] ... +# 338| 6: [ReservedWord] ) +# 339| 3: [BodyStatement] BodyStatement +# 339| 0: [Call] Call +# 339| 0: [Identifier] bar +# 339| 1: [ArgumentList] ArgumentList +# 339| 0: [ReservedWord] ( +# 339| 1: [Identifier] b # 339| 2: [ReservedWord] , -# 339| 3: [Integer] 2 -# 339| 4: [ReservedWord] , -# 339| 5: [Integer] 3 -# 339| 6: [ReservedWord] ] -# 339| 2: [ReservedWord] , -# 339| 3: [Array] Array -# 339| 0: [ReservedWord] [ -# 339| 1: [Integer] 4 -# 339| 2: [ReservedWord] , -# 339| 3: [Integer] 5 -# 339| 4: [ReservedWord] , -# 339| 5: [Integer] 6 -# 339| 6: [ReservedWord] ] -# 339| 4: [ReservedWord] ] -# 339| 3: [Do] Do -# 340| 0: [Call] Call -# 340| 0: [Identifier] foo -# 340| 1: [ArgumentList] ArgumentList -# 340| 0: [Identifier] x -# 340| 1: [ReservedWord] , -# 340| 2: [Identifier] y -# 340| 3: [ReservedWord] , -# 340| 4: [Identifier] z -# 341| 1: [ReservedWord] end -# 343| 109: [Call] Call -# 343| 0: [Identifier] foo -# 343| 1: [ArgumentList] ArgumentList -# 343| 0: [ReservedWord] ( -# 343| 1: [Pair] Pair -# 343| 0: [HashKeySymbol] x -# 343| 1: [ReservedWord] : -# 343| 2: [Integer] 42 -# 343| 2: [ReservedWord] ) -# 344| 110: [Call] Call -# 344| 0: [Identifier] foo -# 344| 1: [ArgumentList] ArgumentList -# 344| 0: [ReservedWord] ( -# 344| 1: [Pair] Pair -# 344| 0: [HashKeySymbol] x -# 344| 1: [ReservedWord] : -# 344| 2: [ReservedWord] , -# 344| 3: [Pair] Pair -# 344| 0: [HashKeySymbol] novar -# 344| 1: [ReservedWord] : -# 344| 4: [ReservedWord] ) -# 345| 111: [Call] Call -# 345| 0: [Identifier] foo -# 345| 1: [ArgumentList] ArgumentList -# 345| 0: [ReservedWord] ( -# 345| 1: [Pair] Pair -# 345| 0: [HashKeySymbol] X -# 345| 1: [ReservedWord] : -# 345| 2: [Integer] 42 -# 345| 2: [ReservedWord] ) -# 346| 112: [Call] Call -# 346| 0: [Identifier] foo -# 346| 1: [ArgumentList] ArgumentList -# 346| 0: [ReservedWord] ( -# 346| 1: [Pair] Pair -# 346| 0: [HashKeySymbol] X -# 346| 1: [ReservedWord] : -# 346| 2: [ReservedWord] ) -# 349| 113: [Assignment] Assignment -# 349| 0: [Identifier] y -# 349| 1: [ReservedWord] = -# 349| 2: [Integer] 1 -# 350| 114: [Assignment] Assignment -# 350| 0: [Identifier] one -# 350| 1: [ReservedWord] = -# 350| 2: [Lambda] Lambda -# 350| 0: [ReservedWord] -> -# 350| 1: [LambdaParameters] LambdaParameters -# 350| 0: [ReservedWord] ( -# 350| 1: [Identifier] x -# 350| 2: [ReservedWord] ) -# 350| 2: [Block] Block -# 350| 0: [ReservedWord] { -# 350| 1: [BlockBody] BlockBody -# 350| 0: [Identifier] y -# 350| 2: [ReservedWord] } -# 351| 115: [Assignment] Assignment -# 351| 0: [Identifier] f -# 351| 1: [ReservedWord] = -# 351| 2: [Lambda] Lambda -# 351| 0: [ReservedWord] -> -# 351| 1: [LambdaParameters] LambdaParameters -# 351| 0: [ReservedWord] ( -# 351| 1: [Identifier] x -# 351| 2: [ReservedWord] ) -# 351| 2: [Block] Block -# 351| 0: [ReservedWord] { -# 351| 1: [BlockBody] BlockBody -# 351| 0: [Call] Call -# 351| 0: [Identifier] foo -# 351| 1: [ArgumentList] ArgumentList -# 351| 0: [Identifier] x -# 351| 2: [ReservedWord] } -# 352| 116: [Assignment] Assignment -# 352| 0: [Identifier] g -# 352| 1: [ReservedWord] = -# 352| 2: [Lambda] Lambda -# 352| 0: [ReservedWord] -> -# 352| 1: [LambdaParameters] LambdaParameters -# 352| 0: [ReservedWord] ( -# 352| 1: [Identifier] x -# 352| 2: [ReservedWord] ) -# 352| 2: [Block] Block -# 352| 0: [ReservedWord] { -# 352| 1: [BlockBody] BlockBody -# 352| 0: [Identifier] unknown_call -# 352| 2: [ReservedWord] } -# 353| 117: [Assignment] Assignment -# 353| 0: [Identifier] h +# 339| 3: [ForwardArgument] ... +# 339| 0: [ReservedWord] ... +# 339| 4: [ReservedWord] ) +# 340| 4: [ReservedWord] end +# 343| 108: [For] For +# 343| 0: [ReservedWord] for +# 343| 1: [LeftAssignmentList] LeftAssignmentList +# 343| 0: [Identifier] x +# 343| 1: [ReservedWord] , +# 343| 2: [Identifier] y +# 343| 3: [ReservedWord] , +# 343| 4: [Identifier] z +# 343| 2: [In] In +# 343| 0: [ReservedWord] in +# 343| 1: [Array] Array +# 343| 0: [ReservedWord] [ +# 343| 1: [Array] Array +# 343| 0: [ReservedWord] [ +# 343| 1: [Integer] 1 +# 343| 2: [ReservedWord] , +# 343| 3: [Integer] 2 +# 343| 4: [ReservedWord] , +# 343| 5: [Integer] 3 +# 343| 6: [ReservedWord] ] +# 343| 2: [ReservedWord] , +# 343| 3: [Array] Array +# 343| 0: [ReservedWord] [ +# 343| 1: [Integer] 4 +# 343| 2: [ReservedWord] , +# 343| 3: [Integer] 5 +# 343| 4: [ReservedWord] , +# 343| 5: [Integer] 6 +# 343| 6: [ReservedWord] ] +# 343| 4: [ReservedWord] ] +# 343| 3: [Do] Do +# 344| 0: [Call] Call +# 344| 0: [Identifier] foo +# 344| 1: [ArgumentList] ArgumentList +# 344| 0: [Identifier] x +# 344| 1: [ReservedWord] , +# 344| 2: [Identifier] y +# 344| 3: [ReservedWord] , +# 344| 4: [Identifier] z +# 345| 1: [ReservedWord] end +# 347| 109: [Call] Call +# 347| 0: [Identifier] foo +# 347| 1: [ArgumentList] ArgumentList +# 347| 0: [ReservedWord] ( +# 347| 1: [Pair] Pair +# 347| 0: [HashKeySymbol] x +# 347| 1: [ReservedWord] : +# 347| 2: [Integer] 42 +# 347| 2: [ReservedWord] ) +# 348| 110: [Call] Call +# 348| 0: [Identifier] foo +# 348| 1: [ArgumentList] ArgumentList +# 348| 0: [ReservedWord] ( +# 348| 1: [Pair] Pair +# 348| 0: [HashKeySymbol] x +# 348| 1: [ReservedWord] : +# 348| 2: [ReservedWord] , +# 348| 3: [Pair] Pair +# 348| 0: [HashKeySymbol] novar +# 348| 1: [ReservedWord] : +# 348| 4: [ReservedWord] ) +# 349| 111: [Call] Call +# 349| 0: [Identifier] foo +# 349| 1: [ArgumentList] ArgumentList +# 349| 0: [ReservedWord] ( +# 349| 1: [Pair] Pair +# 349| 0: [HashKeySymbol] X +# 349| 1: [ReservedWord] : +# 349| 2: [Integer] 42 +# 349| 2: [ReservedWord] ) +# 350| 112: [Call] Call +# 350| 0: [Identifier] foo +# 350| 1: [ArgumentList] ArgumentList +# 350| 0: [ReservedWord] ( +# 350| 1: [Pair] Pair +# 350| 0: [HashKeySymbol] X +# 350| 1: [ReservedWord] : +# 350| 2: [ReservedWord] ) +# 353| 113: [Assignment] Assignment +# 353| 0: [Identifier] y # 353| 1: [ReservedWord] = -# 353| 2: [Lambda] Lambda -# 353| 0: [ReservedWord] -> -# 353| 1: [LambdaParameters] LambdaParameters -# 353| 0: [ReservedWord] ( -# 353| 1: [Identifier] x -# 353| 2: [ReservedWord] ) -# 353| 2: [DoBlock] DoBlock -# 353| 0: [ReservedWord] do -# 354| 1: [BodyStatement] BodyStatement -# 354| 0: [Identifier] x -# 355| 1: [Identifier] y -# 356| 2: [Identifier] unknown_call -# 357| 2: [ReservedWord] end -# 360| 118: [Call] Call -# 360| 0: [Identifier] list -# 360| 1: [ReservedWord] . -# 360| 2: [Identifier] empty? -# 361| 119: [Call] Call -# 361| 0: [Identifier] list -# 361| 1: [ReservedWord] &. -# 361| 2: [Identifier] empty? -# 362| 120: [Call] Call -# 362| 0: [Identifier] list -# 362| 1: [ReservedWord] :: -# 362| 2: [Identifier] empty? -# 363| 121: [Call] Call -# 363| 0: [Identifier] foo -# 363| 1: [ReservedWord] &. -# 363| 2: [Identifier] bar -# 363| 3: [ArgumentList] ArgumentList -# 363| 0: [ReservedWord] ( -# 363| 1: [Integer] 1 -# 363| 2: [ReservedWord] , -# 363| 3: [Integer] 2 -# 363| 4: [ReservedWord] ) -# 363| 4: [Block] Block -# 363| 0: [ReservedWord] { -# 363| 1: [BlockParameters] BlockParameters -# 363| 0: [ReservedWord] | -# 363| 1: [Identifier] x -# 363| 2: [ReservedWord] | -# 363| 2: [BlockBody] BlockBody -# 363| 0: [Identifier] x -# 363| 3: [ReservedWord] } +# 353| 2: [Integer] 1 +# 354| 114: [Assignment] Assignment +# 354| 0: [Identifier] one +# 354| 1: [ReservedWord] = +# 354| 2: [Lambda] Lambda +# 354| 0: [ReservedWord] -> +# 354| 1: [LambdaParameters] LambdaParameters +# 354| 0: [ReservedWord] ( +# 354| 1: [Identifier] x +# 354| 2: [ReservedWord] ) +# 354| 2: [Block] Block +# 354| 0: [ReservedWord] { +# 354| 1: [BlockBody] BlockBody +# 354| 0: [Identifier] y +# 354| 2: [ReservedWord] } +# 355| 115: [Assignment] Assignment +# 355| 0: [Identifier] f +# 355| 1: [ReservedWord] = +# 355| 2: [Lambda] Lambda +# 355| 0: [ReservedWord] -> +# 355| 1: [LambdaParameters] LambdaParameters +# 355| 0: [ReservedWord] ( +# 355| 1: [Identifier] x +# 355| 2: [ReservedWord] ) +# 355| 2: [Block] Block +# 355| 0: [ReservedWord] { +# 355| 1: [BlockBody] BlockBody +# 355| 0: [Call] Call +# 355| 0: [Identifier] foo +# 355| 1: [ArgumentList] ArgumentList +# 355| 0: [Identifier] x +# 355| 2: [ReservedWord] } +# 356| 116: [Assignment] Assignment +# 356| 0: [Identifier] g +# 356| 1: [ReservedWord] = +# 356| 2: [Lambda] Lambda +# 356| 0: [ReservedWord] -> +# 356| 1: [LambdaParameters] LambdaParameters +# 356| 0: [ReservedWord] ( +# 356| 1: [Identifier] x +# 356| 2: [ReservedWord] ) +# 356| 2: [Block] Block +# 356| 0: [ReservedWord] { +# 356| 1: [BlockBody] BlockBody +# 356| 0: [Identifier] unknown_call +# 356| 2: [ReservedWord] } +# 357| 117: [Assignment] Assignment +# 357| 0: [Identifier] h +# 357| 1: [ReservedWord] = +# 357| 2: [Lambda] Lambda +# 357| 0: [ReservedWord] -> +# 357| 1: [LambdaParameters] LambdaParameters +# 357| 0: [ReservedWord] ( +# 357| 1: [Identifier] x +# 357| 2: [ReservedWord] ) +# 357| 2: [DoBlock] DoBlock +# 357| 0: [ReservedWord] do +# 358| 1: [BodyStatement] BodyStatement +# 358| 0: [Identifier] x +# 359| 1: [Identifier] y +# 360| 2: [Identifier] unknown_call +# 361| 2: [ReservedWord] end +# 364| 118: [Call] Call +# 364| 0: [Identifier] list +# 364| 1: [ReservedWord] . +# 364| 2: [Identifier] empty? +# 365| 119: [Call] Call +# 365| 0: [Identifier] list +# 365| 1: [ReservedWord] &. +# 365| 2: [Identifier] empty? +# 366| 120: [Call] Call +# 366| 0: [Identifier] list +# 366| 1: [ReservedWord] :: +# 366| 2: [Identifier] empty? +# 367| 121: [Call] Call +# 367| 0: [Identifier] foo +# 367| 1: [ReservedWord] &. +# 367| 2: [Identifier] bar +# 367| 3: [ArgumentList] ArgumentList +# 367| 0: [ReservedWord] ( +# 367| 1: [Integer] 1 +# 367| 2: [ReservedWord] , +# 367| 3: [Integer] 2 +# 367| 4: [ReservedWord] ) +# 367| 4: [Block] Block +# 367| 0: [ReservedWord] { +# 367| 1: [BlockParameters] BlockParameters +# 367| 0: [ReservedWord] | +# 367| 1: [Identifier] x +# 367| 2: [ReservedWord] | +# 367| 2: [BlockBody] BlockBody +# 367| 0: [Identifier] x +# 367| 3: [ReservedWord] } # 1| [Comment] # call with no receiver, arguments, or block # 4| [Comment] # call whose name is a scope resolution # 7| [Comment] # call with a receiver, no arguments or block @@ -1391,24 +1391,24 @@ calls/calls.rb: # 241| [Comment] # in a range # 245| [Comment] # the key/value in a hash pair # 248| [Comment] # rescue exceptions and ensure -# 258| [Comment] # rescue-modifier body and handler -# 262| [Comment] # block argument -# 266| [Comment] # splat argument -# 271| [Comment] # hash-splat argument -# 276| [Comment] # the value in a keyword argument -# 280| [Comment] # ------------------------------------------------------------------------------ -# 281| [Comment] # calls to `super` -# 296| [Comment] # ------------------------------------------------------------------------------ -# 297| [Comment] # calls to methods simply named `super`, i.e. *not* calls to the same method in -# 298| [Comment] # a parent classs, so these should be Call but not SuperCall -# 304| [Comment] # we expect the receiver to be a SuperCall, while the outer call should not (it's just a regular Call) -# 308| [Comment] # calls without method name -# 312| [Comment] # setter calls -# 321| [Comment] # endless method definitions -# 329| [Comment] # forward parameter and forwarded arguments -# 338| [Comment] # for loop over nested array -# 348| [Comment] # calls inside lambdas -# 359| [Comment] # calls with various call operators +# 262| [Comment] # rescue-modifier body and handler +# 266| [Comment] # block argument +# 270| [Comment] # splat argument +# 275| [Comment] # hash-splat argument +# 280| [Comment] # the value in a keyword argument +# 284| [Comment] # ------------------------------------------------------------------------------ +# 285| [Comment] # calls to `super` +# 300| [Comment] # ------------------------------------------------------------------------------ +# 301| [Comment] # calls to methods simply named `super`, i.e. *not* calls to the same method in +# 302| [Comment] # a parent classs, so these should be Call but not SuperCall +# 308| [Comment] # we expect the receiver to be a SuperCall, while the outer call should not (it's just a regular Call) +# 312| [Comment] # calls without method name +# 316| [Comment] # setter calls +# 325| [Comment] # endless method definitions +# 333| [Comment] # forward parameter and forwarded arguments +# 342| [Comment] # for loop over nested array +# 352| [Comment] # calls inside lambdas +# 363| [Comment] # calls with various call operators constants/constants.rb: # 1| [Program] Program # 1| 0: [Module] Module diff --git a/ruby/ql/test/library-tests/ast/ValueText.expected b/ruby/ql/test/library-tests/ast/ValueText.expected index e0ad853ba83..c3e991b96e7 100644 --- a/ruby/ql/test/library-tests/ast/ValueText.expected +++ b/ruby/ql/test/library-tests/ast/ValueText.expected @@ -12,79 +12,79 @@ exprValue | calls/calls.rb:33:14:33:16 | 200 | 200 | int | | calls/calls.rb:223:5:223:5 | nil | nil | nil | | calls/calls.rb:226:5:226:5 | nil | nil | nil | -| calls/calls.rb:277:5:277:8 | :blah | :blah | symbol | -| calls/calls.rb:278:5:278:8 | :blah | :blah | symbol | -| calls/calls.rb:287:11:287:16 | "blah" | blah | string | -| calls/calls.rb:288:11:288:11 | 1 | 1 | int | -| calls/calls.rb:288:14:288:14 | 2 | 2 | int | -| calls/calls.rb:288:17:288:17 | 3 | 3 | int | -| calls/calls.rb:289:21:289:21 | 1 | 1 | int | -| calls/calls.rb:290:22:290:22 | 2 | 2 | int | -| calls/calls.rb:291:11:291:11 | 4 | 4 | int | -| calls/calls.rb:291:14:291:14 | 5 | 5 | int | -| calls/calls.rb:291:26:291:28 | 100 | 100 | int | -| calls/calls.rb:292:11:292:11 | 6 | 6 | int | -| calls/calls.rb:292:14:292:14 | 7 | 7 | int | -| calls/calls.rb:292:27:292:29 | 200 | 200 | int | -| calls/calls.rb:310:6:310:6 | 1 | 1 | int | -| calls/calls.rb:313:1:313:8 | __synth__0 | 10 | int | -| calls/calls.rb:313:12:313:13 | 10 | 10 | int | -| calls/calls.rb:314:1:314:6 | __synth__0 | 10 | int | -| calls/calls.rb:314:5:314:5 | 0 | 0 | int | -| calls/calls.rb:314:10:314:11 | 10 | 10 | int | -| calls/calls.rb:315:1:315:8 | 0 | 0 | int | -| calls/calls.rb:315:12:315:19 | 1 | 1 | int | -| calls/calls.rb:315:12:315:19 | -2 | -2 | int | -| calls/calls.rb:315:22:315:27 | -1 | -1 | int | -| calls/calls.rb:315:26:315:26 | 4 | 4 | int | -| calls/calls.rb:315:32:315:32 | 1 | 1 | int | -| calls/calls.rb:315:35:315:35 | 2 | 2 | int | -| calls/calls.rb:315:38:315:38 | 3 | 3 | int | -| calls/calls.rb:315:41:315:41 | 4 | 4 | int | -| calls/calls.rb:316:1:316:1 | 0 | 0 | int | -| calls/calls.rb:316:5:316:10 | 1 | 1 | int | -| calls/calls.rb:316:5:316:10 | -1 | -1 | int | -| calls/calls.rb:316:9:316:9 | 5 | 5 | int | -| calls/calls.rb:316:15:316:15 | 1 | 1 | int | -| calls/calls.rb:316:18:316:18 | 2 | 2 | int | -| calls/calls.rb:316:21:316:21 | 3 | 3 | int | -| calls/calls.rb:317:15:317:15 | 1 | 1 | int | +| calls/calls.rb:281:5:281:8 | :blah | :blah | symbol | +| calls/calls.rb:282:5:282:8 | :blah | :blah | symbol | +| calls/calls.rb:291:11:291:16 | "blah" | blah | string | +| calls/calls.rb:292:11:292:11 | 1 | 1 | int | +| calls/calls.rb:292:14:292:14 | 2 | 2 | int | +| calls/calls.rb:292:17:292:17 | 3 | 3 | int | +| calls/calls.rb:293:21:293:21 | 1 | 1 | int | +| calls/calls.rb:294:22:294:22 | 2 | 2 | int | +| calls/calls.rb:295:11:295:11 | 4 | 4 | int | +| calls/calls.rb:295:14:295:14 | 5 | 5 | int | +| calls/calls.rb:295:26:295:28 | 100 | 100 | int | +| calls/calls.rb:296:11:296:11 | 6 | 6 | int | +| calls/calls.rb:296:14:296:14 | 7 | 7 | int | +| calls/calls.rb:296:27:296:29 | 200 | 200 | int | +| calls/calls.rb:314:6:314:6 | 1 | 1 | int | +| calls/calls.rb:317:1:317:8 | __synth__0 | 10 | int | +| calls/calls.rb:317:12:317:13 | 10 | 10 | int | +| calls/calls.rb:318:1:318:6 | __synth__0 | 10 | int | | calls/calls.rb:318:5:318:5 | 0 | 0 | int | -| calls/calls.rb:318:5:318:5 | __synth__1 | 0 | int | -| calls/calls.rb:318:5:318:5 | __synth__1 | 0 | int | -| calls/calls.rb:318:11:318:11 | 1 | 1 | int | -| calls/calls.rb:319:9:319:9 | 0 | 0 | int | -| calls/calls.rb:319:9:319:9 | __synth__1 | 0 | int | -| calls/calls.rb:319:9:319:9 | __synth__1 | 0 | int | -| calls/calls.rb:319:31:319:31 | 1 | 1 | int | -| calls/calls.rb:319:37:319:37 | 2 | 2 | int | -| calls/calls.rb:327:31:327:37 | "error" | error | string | -| calls/calls.rb:339:5:339:5 | 0 | 0 | int | -| calls/calls.rb:339:5:339:5 | nil | nil | nil | -| calls/calls.rb:339:8:339:8 | 1 | 1 | int | -| calls/calls.rb:339:8:339:8 | nil | nil | nil | -| calls/calls.rb:339:11:339:11 | 2 | 2 | int | -| calls/calls.rb:339:11:339:11 | nil | nil | nil | -| calls/calls.rb:339:18:339:18 | 1 | 1 | int | -| calls/calls.rb:339:20:339:20 | 2 | 2 | int | -| calls/calls.rb:339:22:339:22 | 3 | 3 | int | -| calls/calls.rb:339:27:339:27 | 4 | 4 | int | -| calls/calls.rb:339:29:339:29 | 5 | 5 | int | -| calls/calls.rb:339:31:339:31 | 6 | 6 | int | -| calls/calls.rb:343:5:343:5 | :x | :x | symbol | -| calls/calls.rb:343:8:343:9 | 42 | 42 | int | -| calls/calls.rb:344:5:344:5 | :x | :x | symbol | -| calls/calls.rb:344:9:344:13 | :novar | :novar | symbol | -| calls/calls.rb:345:5:345:5 | :X | :X | symbol | -| calls/calls.rb:345:8:345:9 | 42 | 42 | int | -| calls/calls.rb:346:5:346:5 | :X | :X | symbol | -| calls/calls.rb:349:5:349:5 | 1 | 1 | int | -| calls/calls.rb:361:1:361:4 | nil | nil | nil | -| calls/calls.rb:361:5:361:6 | nil | nil | nil | -| calls/calls.rb:363:1:363:3 | nil | nil | nil | -| calls/calls.rb:363:4:363:5 | nil | nil | nil | -| calls/calls.rb:363:10:363:10 | 1 | 1 | int | -| calls/calls.rb:363:12:363:12 | 2 | 2 | int | +| calls/calls.rb:318:10:318:11 | 10 | 10 | int | +| calls/calls.rb:319:1:319:8 | 0 | 0 | int | +| calls/calls.rb:319:12:319:19 | 1 | 1 | int | +| calls/calls.rb:319:12:319:19 | -2 | -2 | int | +| calls/calls.rb:319:22:319:27 | -1 | -1 | int | +| calls/calls.rb:319:26:319:26 | 4 | 4 | int | +| calls/calls.rb:319:32:319:32 | 1 | 1 | int | +| calls/calls.rb:319:35:319:35 | 2 | 2 | int | +| calls/calls.rb:319:38:319:38 | 3 | 3 | int | +| calls/calls.rb:319:41:319:41 | 4 | 4 | int | +| calls/calls.rb:320:1:320:1 | 0 | 0 | int | +| calls/calls.rb:320:5:320:10 | 1 | 1 | int | +| calls/calls.rb:320:5:320:10 | -1 | -1 | int | +| calls/calls.rb:320:9:320:9 | 5 | 5 | int | +| calls/calls.rb:320:15:320:15 | 1 | 1 | int | +| calls/calls.rb:320:18:320:18 | 2 | 2 | int | +| calls/calls.rb:320:21:320:21 | 3 | 3 | int | +| calls/calls.rb:321:15:321:15 | 1 | 1 | int | +| calls/calls.rb:322:5:322:5 | 0 | 0 | int | +| calls/calls.rb:322:5:322:5 | __synth__1 | 0 | int | +| calls/calls.rb:322:5:322:5 | __synth__1 | 0 | int | +| calls/calls.rb:322:11:322:11 | 1 | 1 | int | +| calls/calls.rb:323:9:323:9 | 0 | 0 | int | +| calls/calls.rb:323:9:323:9 | __synth__1 | 0 | int | +| calls/calls.rb:323:9:323:9 | __synth__1 | 0 | int | +| calls/calls.rb:323:31:323:31 | 1 | 1 | int | +| calls/calls.rb:323:37:323:37 | 2 | 2 | int | +| calls/calls.rb:331:31:331:37 | "error" | error | string | +| calls/calls.rb:343:5:343:5 | 0 | 0 | int | +| calls/calls.rb:343:5:343:5 | nil | nil | nil | +| calls/calls.rb:343:8:343:8 | 1 | 1 | int | +| calls/calls.rb:343:8:343:8 | nil | nil | nil | +| calls/calls.rb:343:11:343:11 | 2 | 2 | int | +| calls/calls.rb:343:11:343:11 | nil | nil | nil | +| calls/calls.rb:343:18:343:18 | 1 | 1 | int | +| calls/calls.rb:343:20:343:20 | 2 | 2 | int | +| calls/calls.rb:343:22:343:22 | 3 | 3 | int | +| calls/calls.rb:343:27:343:27 | 4 | 4 | int | +| calls/calls.rb:343:29:343:29 | 5 | 5 | int | +| calls/calls.rb:343:31:343:31 | 6 | 6 | int | +| calls/calls.rb:347:5:347:5 | :x | :x | symbol | +| calls/calls.rb:347:8:347:9 | 42 | 42 | int | +| calls/calls.rb:348:5:348:5 | :x | :x | symbol | +| calls/calls.rb:348:9:348:13 | :novar | :novar | symbol | +| calls/calls.rb:349:5:349:5 | :X | :X | symbol | +| calls/calls.rb:349:8:349:9 | 42 | 42 | int | +| calls/calls.rb:350:5:350:5 | :X | :X | symbol | +| calls/calls.rb:353:5:353:5 | 1 | 1 | int | +| calls/calls.rb:365:1:365:4 | nil | nil | nil | +| calls/calls.rb:365:5:365:6 | nil | nil | nil | +| calls/calls.rb:367:1:367:3 | nil | nil | nil | +| calls/calls.rb:367:4:367:5 | nil | nil | nil | +| calls/calls.rb:367:10:367:10 | 1 | 1 | int | +| calls/calls.rb:367:12:367:12 | 2 | 2 | int | | constants/constants.rb:3:19:3:27 | "const_a" | const_a | string | | constants/constants.rb:6:15:6:23 | "const_b" | const_b | string | | constants/constants.rb:17:12:17:18 | "Hello" | Hello | string | @@ -975,79 +975,79 @@ exprCfgNodeValue | calls/calls.rb:33:14:33:16 | 200 | 200 | int | | calls/calls.rb:223:5:223:5 | nil | nil | nil | | calls/calls.rb:226:5:226:5 | nil | nil | nil | -| calls/calls.rb:277:5:277:8 | :blah | :blah | symbol | -| calls/calls.rb:278:5:278:8 | :blah | :blah | symbol | -| calls/calls.rb:287:11:287:16 | "blah" | blah | string | -| calls/calls.rb:288:11:288:11 | 1 | 1 | int | -| calls/calls.rb:288:14:288:14 | 2 | 2 | int | -| calls/calls.rb:288:17:288:17 | 3 | 3 | int | -| calls/calls.rb:289:21:289:21 | 1 | 1 | int | -| calls/calls.rb:290:22:290:22 | 2 | 2 | int | -| calls/calls.rb:291:11:291:11 | 4 | 4 | int | -| calls/calls.rb:291:14:291:14 | 5 | 5 | int | -| calls/calls.rb:291:26:291:28 | 100 | 100 | int | -| calls/calls.rb:292:11:292:11 | 6 | 6 | int | -| calls/calls.rb:292:14:292:14 | 7 | 7 | int | -| calls/calls.rb:292:27:292:29 | 200 | 200 | int | -| calls/calls.rb:310:6:310:6 | 1 | 1 | int | -| calls/calls.rb:313:1:313:8 | __synth__0 | 10 | int | -| calls/calls.rb:313:12:313:13 | 10 | 10 | int | -| calls/calls.rb:314:1:314:6 | __synth__0 | 10 | int | -| calls/calls.rb:314:5:314:5 | 0 | 0 | int | -| calls/calls.rb:314:10:314:11 | 10 | 10 | int | -| calls/calls.rb:315:1:315:8 | 0 | 0 | int | -| calls/calls.rb:315:12:315:19 | 1 | 1 | int | -| calls/calls.rb:315:12:315:19 | -2 | -2 | int | -| calls/calls.rb:315:22:315:27 | -1 | -1 | int | -| calls/calls.rb:315:26:315:26 | 4 | 4 | int | -| calls/calls.rb:315:32:315:32 | 1 | 1 | int | -| calls/calls.rb:315:35:315:35 | 2 | 2 | int | -| calls/calls.rb:315:38:315:38 | 3 | 3 | int | -| calls/calls.rb:315:41:315:41 | 4 | 4 | int | -| calls/calls.rb:316:1:316:1 | 0 | 0 | int | -| calls/calls.rb:316:5:316:10 | 1 | 1 | int | -| calls/calls.rb:316:5:316:10 | -1 | -1 | int | -| calls/calls.rb:316:9:316:9 | 5 | 5 | int | -| calls/calls.rb:316:15:316:15 | 1 | 1 | int | -| calls/calls.rb:316:18:316:18 | 2 | 2 | int | -| calls/calls.rb:316:21:316:21 | 3 | 3 | int | -| calls/calls.rb:317:15:317:15 | 1 | 1 | int | +| calls/calls.rb:281:5:281:8 | :blah | :blah | symbol | +| calls/calls.rb:282:5:282:8 | :blah | :blah | symbol | +| calls/calls.rb:291:11:291:16 | "blah" | blah | string | +| calls/calls.rb:292:11:292:11 | 1 | 1 | int | +| calls/calls.rb:292:14:292:14 | 2 | 2 | int | +| calls/calls.rb:292:17:292:17 | 3 | 3 | int | +| calls/calls.rb:293:21:293:21 | 1 | 1 | int | +| calls/calls.rb:294:22:294:22 | 2 | 2 | int | +| calls/calls.rb:295:11:295:11 | 4 | 4 | int | +| calls/calls.rb:295:14:295:14 | 5 | 5 | int | +| calls/calls.rb:295:26:295:28 | 100 | 100 | int | +| calls/calls.rb:296:11:296:11 | 6 | 6 | int | +| calls/calls.rb:296:14:296:14 | 7 | 7 | int | +| calls/calls.rb:296:27:296:29 | 200 | 200 | int | +| calls/calls.rb:314:6:314:6 | 1 | 1 | int | +| calls/calls.rb:317:1:317:8 | __synth__0 | 10 | int | +| calls/calls.rb:317:12:317:13 | 10 | 10 | int | +| calls/calls.rb:318:1:318:6 | __synth__0 | 10 | int | | calls/calls.rb:318:5:318:5 | 0 | 0 | int | -| calls/calls.rb:318:5:318:5 | __synth__1 | 0 | int | -| calls/calls.rb:318:5:318:5 | __synth__1 | 0 | int | -| calls/calls.rb:318:11:318:11 | 1 | 1 | int | -| calls/calls.rb:319:9:319:9 | 0 | 0 | int | -| calls/calls.rb:319:9:319:9 | __synth__1 | 0 | int | -| calls/calls.rb:319:9:319:9 | __synth__1 | 0 | int | -| calls/calls.rb:319:31:319:31 | 1 | 1 | int | -| calls/calls.rb:319:37:319:37 | 2 | 2 | int | -| calls/calls.rb:327:31:327:37 | "error" | error | string | -| calls/calls.rb:339:5:339:5 | 0 | 0 | int | -| calls/calls.rb:339:5:339:5 | nil | nil | nil | -| calls/calls.rb:339:8:339:8 | 1 | 1 | int | -| calls/calls.rb:339:8:339:8 | nil | nil | nil | -| calls/calls.rb:339:11:339:11 | 2 | 2 | int | -| calls/calls.rb:339:11:339:11 | nil | nil | nil | -| calls/calls.rb:339:18:339:18 | 1 | 1 | int | -| calls/calls.rb:339:20:339:20 | 2 | 2 | int | -| calls/calls.rb:339:22:339:22 | 3 | 3 | int | -| calls/calls.rb:339:27:339:27 | 4 | 4 | int | -| calls/calls.rb:339:29:339:29 | 5 | 5 | int | -| calls/calls.rb:339:31:339:31 | 6 | 6 | int | -| calls/calls.rb:343:5:343:5 | :x | :x | symbol | -| calls/calls.rb:343:8:343:9 | 42 | 42 | int | -| calls/calls.rb:344:5:344:5 | :x | :x | symbol | -| calls/calls.rb:344:9:344:13 | :novar | :novar | symbol | -| calls/calls.rb:345:5:345:5 | :X | :X | symbol | -| calls/calls.rb:345:8:345:9 | 42 | 42 | int | -| calls/calls.rb:346:5:346:5 | :X | :X | symbol | -| calls/calls.rb:349:5:349:5 | 1 | 1 | int | -| calls/calls.rb:361:1:361:4 | nil | nil | nil | -| calls/calls.rb:361:5:361:6 | nil | nil | nil | -| calls/calls.rb:363:1:363:3 | nil | nil | nil | -| calls/calls.rb:363:4:363:5 | nil | nil | nil | -| calls/calls.rb:363:10:363:10 | 1 | 1 | int | -| calls/calls.rb:363:12:363:12 | 2 | 2 | int | +| calls/calls.rb:318:10:318:11 | 10 | 10 | int | +| calls/calls.rb:319:1:319:8 | 0 | 0 | int | +| calls/calls.rb:319:12:319:19 | 1 | 1 | int | +| calls/calls.rb:319:12:319:19 | -2 | -2 | int | +| calls/calls.rb:319:22:319:27 | -1 | -1 | int | +| calls/calls.rb:319:26:319:26 | 4 | 4 | int | +| calls/calls.rb:319:32:319:32 | 1 | 1 | int | +| calls/calls.rb:319:35:319:35 | 2 | 2 | int | +| calls/calls.rb:319:38:319:38 | 3 | 3 | int | +| calls/calls.rb:319:41:319:41 | 4 | 4 | int | +| calls/calls.rb:320:1:320:1 | 0 | 0 | int | +| calls/calls.rb:320:5:320:10 | 1 | 1 | int | +| calls/calls.rb:320:5:320:10 | -1 | -1 | int | +| calls/calls.rb:320:9:320:9 | 5 | 5 | int | +| calls/calls.rb:320:15:320:15 | 1 | 1 | int | +| calls/calls.rb:320:18:320:18 | 2 | 2 | int | +| calls/calls.rb:320:21:320:21 | 3 | 3 | int | +| calls/calls.rb:321:15:321:15 | 1 | 1 | int | +| calls/calls.rb:322:5:322:5 | 0 | 0 | int | +| calls/calls.rb:322:5:322:5 | __synth__1 | 0 | int | +| calls/calls.rb:322:5:322:5 | __synth__1 | 0 | int | +| calls/calls.rb:322:11:322:11 | 1 | 1 | int | +| calls/calls.rb:323:9:323:9 | 0 | 0 | int | +| calls/calls.rb:323:9:323:9 | __synth__1 | 0 | int | +| calls/calls.rb:323:9:323:9 | __synth__1 | 0 | int | +| calls/calls.rb:323:31:323:31 | 1 | 1 | int | +| calls/calls.rb:323:37:323:37 | 2 | 2 | int | +| calls/calls.rb:331:31:331:37 | "error" | error | string | +| calls/calls.rb:343:5:343:5 | 0 | 0 | int | +| calls/calls.rb:343:5:343:5 | nil | nil | nil | +| calls/calls.rb:343:8:343:8 | 1 | 1 | int | +| calls/calls.rb:343:8:343:8 | nil | nil | nil | +| calls/calls.rb:343:11:343:11 | 2 | 2 | int | +| calls/calls.rb:343:11:343:11 | nil | nil | nil | +| calls/calls.rb:343:18:343:18 | 1 | 1 | int | +| calls/calls.rb:343:20:343:20 | 2 | 2 | int | +| calls/calls.rb:343:22:343:22 | 3 | 3 | int | +| calls/calls.rb:343:27:343:27 | 4 | 4 | int | +| calls/calls.rb:343:29:343:29 | 5 | 5 | int | +| calls/calls.rb:343:31:343:31 | 6 | 6 | int | +| calls/calls.rb:347:5:347:5 | :x | :x | symbol | +| calls/calls.rb:347:8:347:9 | 42 | 42 | int | +| calls/calls.rb:348:5:348:5 | :x | :x | symbol | +| calls/calls.rb:348:9:348:13 | :novar | :novar | symbol | +| calls/calls.rb:349:5:349:5 | :X | :X | symbol | +| calls/calls.rb:349:8:349:9 | 42 | 42 | int | +| calls/calls.rb:350:5:350:5 | :X | :X | symbol | +| calls/calls.rb:353:5:353:5 | 1 | 1 | int | +| calls/calls.rb:365:1:365:4 | nil | nil | nil | +| calls/calls.rb:365:5:365:6 | nil | nil | nil | +| calls/calls.rb:367:1:367:3 | nil | nil | nil | +| calls/calls.rb:367:4:367:5 | nil | nil | nil | +| calls/calls.rb:367:10:367:10 | 1 | 1 | int | +| calls/calls.rb:367:12:367:12 | 2 | 2 | int | | constants/constants.rb:3:19:3:27 | "const_a" | const_a | string | | constants/constants.rb:6:15:6:23 | "const_b" | const_b | string | | constants/constants.rb:17:12:17:18 | "Hello" | Hello | string | diff --git a/ruby/ql/test/library-tests/ast/calls/arguments.expected b/ruby/ql/test/library-tests/ast/calls/arguments.expected index 0a7ec104b64..4a2f1e10e95 100644 --- a/ruby/ql/test/library-tests/ast/calls/arguments.expected +++ b/ruby/ql/test/library-tests/ast/calls/arguments.expected @@ -1,30 +1,30 @@ blockArguments -| calls.rb:263:5:263:8 | &... | calls.rb:263:6:263:8 | call to bar | -| calls.rb:264:5:264:11 | &... | calls.rb:264:6:264:11 | call to bar | +| calls.rb:267:5:267:8 | &... | calls.rb:267:6:267:8 | call to bar | +| calls.rb:268:5:268:11 | &... | calls.rb:268:6:268:11 | call to bar | splatExpr -| calls.rb:267:5:267:8 | * ... | calls.rb:267:6:267:8 | call to bar | -| calls.rb:268:5:268:11 | * ... | calls.rb:268:6:268:11 | call to bar | -| calls.rb:315:31:315:42 | * ... | calls.rb:315:31:315:42 | [...] | -| calls.rb:316:14:316:22 | * ... | calls.rb:316:14:316:22 | [...] | -| calls.rb:339:1:341:3 | * ... | calls.rb:339:1:341:3 | __synth__0__1 | +| calls.rb:271:5:271:8 | * ... | calls.rb:271:6:271:8 | call to bar | +| calls.rb:272:5:272:11 | * ... | calls.rb:272:6:272:11 | call to bar | +| calls.rb:319:31:319:42 | * ... | calls.rb:319:31:319:42 | [...] | +| calls.rb:320:14:320:22 | * ... | calls.rb:320:14:320:22 | [...] | +| calls.rb:343:1:345:3 | * ... | calls.rb:343:1:345:3 | __synth__0__1 | hashSplatExpr -| calls.rb:272:5:272:9 | ** ... | calls.rb:272:7:272:9 | call to bar | -| calls.rb:273:5:273:12 | ** ... | calls.rb:273:7:273:12 | call to bar | +| calls.rb:276:5:276:9 | ** ... | calls.rb:276:7:276:9 | call to bar | +| calls.rb:277:5:277:12 | ** ... | calls.rb:277:7:277:12 | call to bar | keywordArguments | calls.rb:246:3:246:12 | Pair | calls.rb:246:3:246:5 | call to foo | calls.rb:246:10:246:12 | call to bar | | calls.rb:246:15:246:30 | Pair | calls.rb:246:15:246:20 | call to foo | calls.rb:246:25:246:30 | call to bar | -| calls.rb:277:5:277:13 | Pair | calls.rb:277:5:277:8 | :blah | calls.rb:277:11:277:13 | call to bar | -| calls.rb:278:5:278:16 | Pair | calls.rb:278:5:278:8 | :blah | calls.rb:278:11:278:16 | call to bar | -| calls.rb:343:5:343:9 | Pair | calls.rb:343:5:343:5 | :x | calls.rb:343:8:343:9 | 42 | -| calls.rb:344:5:344:6 | Pair | calls.rb:344:5:344:5 | :x | calls.rb:344:5:344:5 | x | -| calls.rb:344:9:344:14 | Pair | calls.rb:344:9:344:13 | :novar | calls.rb:344:9:344:13 | call to novar | -| calls.rb:345:5:345:9 | Pair | calls.rb:345:5:345:5 | :X | calls.rb:345:8:345:9 | 42 | -| calls.rb:346:5:346:6 | Pair | calls.rb:346:5:346:5 | :X | calls.rb:346:5:346:5 | X | +| calls.rb:281:5:281:13 | Pair | calls.rb:281:5:281:8 | :blah | calls.rb:281:11:281:13 | call to bar | +| calls.rb:282:5:282:16 | Pair | calls.rb:282:5:282:8 | :blah | calls.rb:282:11:282:16 | call to bar | +| calls.rb:347:5:347:9 | Pair | calls.rb:347:5:347:5 | :x | calls.rb:347:8:347:9 | 42 | +| calls.rb:348:5:348:6 | Pair | calls.rb:348:5:348:5 | :x | calls.rb:348:5:348:5 | x | +| calls.rb:348:9:348:14 | Pair | calls.rb:348:9:348:13 | :novar | calls.rb:348:9:348:13 | call to novar | +| calls.rb:349:5:349:9 | Pair | calls.rb:349:5:349:5 | :X | calls.rb:349:8:349:9 | 42 | +| calls.rb:350:5:350:6 | Pair | calls.rb:350:5:350:5 | :X | calls.rb:350:5:350:5 | X | keywordArgumentsByKeyword -| calls.rb:277:1:277:14 | call to foo | blah | calls.rb:277:11:277:13 | call to bar | -| calls.rb:278:1:278:17 | call to foo | blah | calls.rb:278:11:278:16 | call to bar | -| calls.rb:343:1:343:10 | call to foo | x | calls.rb:343:8:343:9 | 42 | -| calls.rb:344:1:344:15 | call to foo | novar | calls.rb:344:9:344:13 | call to novar | -| calls.rb:344:1:344:15 | call to foo | x | calls.rb:344:5:344:5 | x | -| calls.rb:345:1:345:10 | call to foo | X | calls.rb:345:8:345:9 | 42 | -| calls.rb:346:1:346:7 | call to foo | X | calls.rb:346:5:346:5 | X | +| calls.rb:281:1:281:14 | call to foo | blah | calls.rb:281:11:281:13 | call to bar | +| calls.rb:282:1:282:17 | call to foo | blah | calls.rb:282:11:282:16 | call to bar | +| calls.rb:347:1:347:10 | call to foo | x | calls.rb:347:8:347:9 | 42 | +| calls.rb:348:1:348:15 | call to foo | novar | calls.rb:348:9:348:13 | call to novar | +| calls.rb:348:1:348:15 | call to foo | x | calls.rb:348:5:348:5 | x | +| calls.rb:349:1:349:10 | call to foo | X | calls.rb:349:8:349:9 | 42 | +| calls.rb:350:1:350:7 | call to foo | X | calls.rb:350:5:350:5 | X | diff --git a/ruby/ql/test/library-tests/ast/calls/calls.expected b/ruby/ql/test/library-tests/ast/calls/calls.expected index f5af4c89ba6..4d9b7c9fdf8 100644 --- a/ruby/ql/test/library-tests/ast/calls/calls.expected +++ b/ruby/ql/test/library-tests/ast/calls/calls.expected @@ -1,11 +1,11 @@ callsWithNoReceiverArgumentsOrBlock | calls.rb:28:3:28:7 | yield ... | (none) | -| calls.rb:269:5:269:5 | * ... | * | -| calls.rb:274:5:274:6 | ** ... | ** | -| calls.rb:285:5:285:9 | super call to my_method | my_method | -| calls.rb:286:5:286:11 | super call to my_method | my_method | -| calls.rb:304:5:304:9 | super call to another_method | another_method | -| calls.rb:344:9:344:13 | call to novar | novar | +| calls.rb:273:5:273:5 | * ... | * | +| calls.rb:278:5:278:6 | ** ... | ** | +| calls.rb:289:5:289:9 | super call to my_method | my_method | +| calls.rb:290:5:290:11 | super call to my_method | my_method | +| calls.rb:308:5:308:9 | super call to another_method | another_method | +| calls.rb:348:9:348:13 | call to novar | novar | callsWithArguments | calls.rb:11:1:11:11 | call to foo | foo | 0 | calls.rb:11:5:11:5 | 0 | | calls.rb:11:1:11:11 | call to foo | foo | 1 | calls.rb:11:8:11:8 | 1 | @@ -27,105 +27,105 @@ callsWithArguments | calls.rb:232:1:232:14 | ...[...] | [] | 0 | calls.rb:232:8:232:13 | call to bar | | calls.rb:246:1:246:32 | call to [] | [] | 0 | calls.rb:246:3:246:12 | Pair | | calls.rb:246:1:246:32 | call to [] | [] | 1 | calls.rb:246:15:246:30 | Pair | -| calls.rb:263:1:263:9 | call to foo | foo | 0 | calls.rb:263:5:263:8 | &... | -| calls.rb:264:1:264:12 | call to foo | foo | 0 | calls.rb:264:5:264:11 | &... | -| calls.rb:265:1:265:6 | call to foo | foo | 0 | calls.rb:265:5:265:5 | &... | -| calls.rb:267:1:267:9 | call to foo | foo | 0 | calls.rb:267:5:267:8 | * ... | -| calls.rb:268:1:268:12 | call to foo | foo | 0 | calls.rb:268:5:268:11 | * ... | -| calls.rb:269:1:269:6 | call to foo | foo | 0 | calls.rb:269:5:269:5 | * ... | -| calls.rb:272:1:272:10 | call to foo | foo | 0 | calls.rb:272:5:272:9 | ** ... | -| calls.rb:273:1:273:13 | call to foo | foo | 0 | calls.rb:273:5:273:12 | ** ... | -| calls.rb:274:1:274:7 | call to foo | foo | 0 | calls.rb:274:5:274:6 | ** ... | -| calls.rb:277:1:277:14 | call to foo | foo | 0 | calls.rb:277:5:277:13 | Pair | -| calls.rb:278:1:278:17 | call to foo | foo | 0 | calls.rb:278:5:278:16 | Pair | -| calls.rb:287:5:287:16 | super call to my_method | my_method | 0 | calls.rb:287:11:287:16 | "blah" | -| calls.rb:288:5:288:17 | super call to my_method | my_method | 0 | calls.rb:288:11:288:11 | 1 | -| calls.rb:288:5:288:17 | super call to my_method | my_method | 1 | calls.rb:288:14:288:14 | 2 | -| calls.rb:288:5:288:17 | super call to my_method | my_method | 2 | calls.rb:288:17:288:17 | 3 | -| calls.rb:289:17:289:21 | ... + ... | + | 0 | calls.rb:289:21:289:21 | 1 | -| calls.rb:290:18:290:22 | ... * ... | * | 0 | calls.rb:290:22:290:22 | 2 | -| calls.rb:291:5:291:30 | super call to my_method | my_method | 0 | calls.rb:291:11:291:11 | 4 | -| calls.rb:291:5:291:30 | super call to my_method | my_method | 1 | calls.rb:291:14:291:14 | 5 | -| calls.rb:291:22:291:28 | ... + ... | + | 0 | calls.rb:291:26:291:28 | 100 | -| calls.rb:292:5:292:33 | super call to my_method | my_method | 0 | calls.rb:292:11:292:11 | 6 | -| calls.rb:292:5:292:33 | super call to my_method | my_method | 1 | calls.rb:292:14:292:14 | 7 | -| calls.rb:292:23:292:29 | ... + ... | + | 0 | calls.rb:292:27:292:29 | 200 | -| calls.rb:310:1:310:7 | call to call | call | 0 | calls.rb:310:6:310:6 | 1 | -| calls.rb:313:1:313:8 | call to foo= | foo= | 0 | calls.rb:313:12:313:13 | ... = ... | -| calls.rb:314:1:314:6 | ...[...] | [] | 0 | calls.rb:314:5:314:5 | 0 | -| calls.rb:314:1:314:6 | call to []= | []= | 0 | calls.rb:314:5:314:5 | 0 | -| calls.rb:314:1:314:6 | call to []= | []= | 1 | calls.rb:314:10:314:11 | ... = ... | -| calls.rb:315:1:315:8 | call to [] | [] | 0 | calls.rb:315:1:315:8 | 0 | -| calls.rb:315:1:315:8 | call to foo= | foo= | 0 | calls.rb:315:1:315:8 | ... = ... | -| calls.rb:315:12:315:19 | call to [] | [] | 0 | calls.rb:315:12:315:19 | _ .. _ | -| calls.rb:315:12:315:19 | call to bar= | bar= | 0 | calls.rb:315:12:315:19 | ... = ... | -| calls.rb:315:22:315:27 | ...[...] | [] | 0 | calls.rb:315:26:315:26 | 4 | -| calls.rb:315:22:315:27 | call to [] | [] | 0 | calls.rb:315:22:315:27 | -1 | -| calls.rb:315:22:315:27 | call to [] | [] | 0 | calls.rb:315:26:315:26 | 4 | -| calls.rb:315:22:315:27 | call to []= | []= | 0 | calls.rb:315:26:315:26 | 4 | -| calls.rb:315:22:315:27 | call to []= | []= | 1 | calls.rb:315:22:315:27 | ... = ... | -| calls.rb:315:31:315:42 | call to [] | [] | 0 | calls.rb:315:32:315:32 | 1 | -| calls.rb:315:31:315:42 | call to [] | [] | 1 | calls.rb:315:35:315:35 | 2 | -| calls.rb:315:31:315:42 | call to [] | [] | 2 | calls.rb:315:38:315:38 | 3 | -| calls.rb:315:31:315:42 | call to [] | [] | 3 | calls.rb:315:41:315:41 | 4 | -| calls.rb:316:1:316:1 | call to [] | [] | 0 | calls.rb:316:1:316:1 | 0 | -| calls.rb:316:5:316:10 | ...[...] | [] | 0 | calls.rb:316:9:316:9 | 5 | -| calls.rb:316:5:316:10 | call to [] | [] | 0 | calls.rb:316:5:316:10 | _ .. _ | -| calls.rb:316:5:316:10 | call to [] | [] | 0 | calls.rb:316:9:316:9 | 5 | -| calls.rb:316:5:316:10 | call to []= | []= | 0 | calls.rb:316:9:316:9 | 5 | -| calls.rb:316:5:316:10 | call to []= | []= | 1 | calls.rb:316:5:316:10 | ... = ... | -| calls.rb:316:14:316:22 | call to [] | [] | 0 | calls.rb:316:15:316:15 | 1 | -| calls.rb:316:14:316:22 | call to [] | [] | 1 | calls.rb:316:18:316:18 | 2 | -| calls.rb:316:14:316:22 | call to [] | [] | 2 | calls.rb:316:21:316:21 | 3 | -| calls.rb:317:1:317:10 | call to count= | count= | 0 | calls.rb:317:1:317:10 | __synth__1 | -| calls.rb:317:12:317:13 | ... + ... | + | 0 | calls.rb:317:15:317:15 | 1 | +| calls.rb:267:1:267:9 | call to foo | foo | 0 | calls.rb:267:5:267:8 | &... | +| calls.rb:268:1:268:12 | call to foo | foo | 0 | calls.rb:268:5:268:11 | &... | +| calls.rb:269:1:269:6 | call to foo | foo | 0 | calls.rb:269:5:269:5 | &... | +| calls.rb:271:1:271:9 | call to foo | foo | 0 | calls.rb:271:5:271:8 | * ... | +| calls.rb:272:1:272:12 | call to foo | foo | 0 | calls.rb:272:5:272:11 | * ... | +| calls.rb:273:1:273:6 | call to foo | foo | 0 | calls.rb:273:5:273:5 | * ... | +| calls.rb:276:1:276:10 | call to foo | foo | 0 | calls.rb:276:5:276:9 | ** ... | +| calls.rb:277:1:277:13 | call to foo | foo | 0 | calls.rb:277:5:277:12 | ** ... | +| calls.rb:278:1:278:7 | call to foo | foo | 0 | calls.rb:278:5:278:6 | ** ... | +| calls.rb:281:1:281:14 | call to foo | foo | 0 | calls.rb:281:5:281:13 | Pair | +| calls.rb:282:1:282:17 | call to foo | foo | 0 | calls.rb:282:5:282:16 | Pair | +| calls.rb:291:5:291:16 | super call to my_method | my_method | 0 | calls.rb:291:11:291:16 | "blah" | +| calls.rb:292:5:292:17 | super call to my_method | my_method | 0 | calls.rb:292:11:292:11 | 1 | +| calls.rb:292:5:292:17 | super call to my_method | my_method | 1 | calls.rb:292:14:292:14 | 2 | +| calls.rb:292:5:292:17 | super call to my_method | my_method | 2 | calls.rb:292:17:292:17 | 3 | +| calls.rb:293:17:293:21 | ... + ... | + | 0 | calls.rb:293:21:293:21 | 1 | +| calls.rb:294:18:294:22 | ... * ... | * | 0 | calls.rb:294:22:294:22 | 2 | +| calls.rb:295:5:295:30 | super call to my_method | my_method | 0 | calls.rb:295:11:295:11 | 4 | +| calls.rb:295:5:295:30 | super call to my_method | my_method | 1 | calls.rb:295:14:295:14 | 5 | +| calls.rb:295:22:295:28 | ... + ... | + | 0 | calls.rb:295:26:295:28 | 100 | +| calls.rb:296:5:296:33 | super call to my_method | my_method | 0 | calls.rb:296:11:296:11 | 6 | +| calls.rb:296:5:296:33 | super call to my_method | my_method | 1 | calls.rb:296:14:296:14 | 7 | +| calls.rb:296:23:296:29 | ... + ... | + | 0 | calls.rb:296:27:296:29 | 200 | +| calls.rb:314:1:314:7 | call to call | call | 0 | calls.rb:314:6:314:6 | 1 | +| calls.rb:317:1:317:8 | call to foo= | foo= | 0 | calls.rb:317:12:317:13 | ... = ... | | calls.rb:318:1:318:6 | ...[...] | [] | 0 | calls.rb:318:5:318:5 | 0 | -| calls.rb:318:1:318:6 | call to [] | [] | 0 | calls.rb:318:5:318:5 | __synth__1 | -| calls.rb:318:1:318:6 | call to []= | []= | 0 | calls.rb:318:5:318:5 | __synth__1 | -| calls.rb:318:1:318:6 | call to []= | []= | 1 | calls.rb:318:1:318:6 | __synth__2 | -| calls.rb:318:8:318:9 | ... + ... | + | 0 | calls.rb:318:11:318:11 | 1 | -| calls.rb:319:1:319:32 | ...[...] | [] | 0 | calls.rb:319:9:319:9 | 0 | -| calls.rb:319:1:319:32 | ...[...] | [] | 1 | calls.rb:319:12:319:18 | call to baz | -| calls.rb:319:1:319:32 | ...[...] | [] | 2 | calls.rb:319:21:319:31 | ... + ... | -| calls.rb:319:1:319:32 | call to [] | [] | 0 | calls.rb:319:9:319:9 | __synth__1 | -| calls.rb:319:1:319:32 | call to [] | [] | 1 | calls.rb:319:12:319:18 | __synth__2 | -| calls.rb:319:1:319:32 | call to [] | [] | 2 | calls.rb:319:21:319:31 | __synth__3 | -| calls.rb:319:1:319:32 | call to []= | []= | 0 | calls.rb:319:9:319:9 | __synth__1 | -| calls.rb:319:1:319:32 | call to []= | []= | 1 | calls.rb:319:12:319:18 | __synth__2 | -| calls.rb:319:1:319:32 | call to []= | []= | 2 | calls.rb:319:21:319:31 | __synth__3 | -| calls.rb:319:1:319:32 | call to []= | []= | 3 | calls.rb:319:1:319:32 | __synth__4 | -| calls.rb:319:21:319:31 | ... + ... | + | 0 | calls.rb:319:31:319:31 | 1 | -| calls.rb:319:34:319:35 | ... * ... | * | 0 | calls.rb:319:37:319:37 | 2 | -| calls.rb:327:25:327:37 | call to print | print | 0 | calls.rb:327:31:327:37 | "error" | -| calls.rb:331:3:331:12 | super call to foo | foo | 0 | calls.rb:331:9:331:11 | ... | -| calls.rb:335:3:335:13 | call to bar | bar | 0 | calls.rb:335:7:335:7 | b | -| calls.rb:335:3:335:13 | call to bar | bar | 1 | calls.rb:335:10:335:12 | ... | -| calls.rb:339:5:339:5 | call to [] | [] | 0 | calls.rb:339:5:339:5 | 0 | -| calls.rb:339:8:339:8 | call to [] | [] | 0 | calls.rb:339:8:339:8 | 1 | -| calls.rb:339:11:339:11 | call to [] | [] | 0 | calls.rb:339:11:339:11 | 2 | -| calls.rb:339:16:339:33 | call to [] | [] | 0 | calls.rb:339:17:339:23 | [...] | -| calls.rb:339:16:339:33 | call to [] | [] | 1 | calls.rb:339:26:339:32 | [...] | -| calls.rb:339:17:339:23 | call to [] | [] | 0 | calls.rb:339:18:339:18 | 1 | -| calls.rb:339:17:339:23 | call to [] | [] | 1 | calls.rb:339:20:339:20 | 2 | -| calls.rb:339:17:339:23 | call to [] | [] | 2 | calls.rb:339:22:339:22 | 3 | -| calls.rb:339:26:339:32 | call to [] | [] | 0 | calls.rb:339:27:339:27 | 4 | -| calls.rb:339:26:339:32 | call to [] | [] | 1 | calls.rb:339:29:339:29 | 5 | -| calls.rb:339:26:339:32 | call to [] | [] | 2 | calls.rb:339:31:339:31 | 6 | -| calls.rb:340:3:340:13 | call to foo | foo | 0 | calls.rb:340:7:340:7 | x | -| calls.rb:340:3:340:13 | call to foo | foo | 1 | calls.rb:340:10:340:10 | y | -| calls.rb:340:3:340:13 | call to foo | foo | 2 | calls.rb:340:13:340:13 | z | -| calls.rb:343:1:343:10 | call to foo | foo | 0 | calls.rb:343:5:343:9 | Pair | -| calls.rb:344:1:344:15 | call to foo | foo | 0 | calls.rb:344:5:344:6 | Pair | -| calls.rb:344:1:344:15 | call to foo | foo | 1 | calls.rb:344:9:344:14 | Pair | -| calls.rb:345:1:345:10 | call to foo | foo | 0 | calls.rb:345:5:345:9 | Pair | -| calls.rb:346:1:346:7 | call to foo | foo | 0 | calls.rb:346:5:346:6 | Pair | -| calls.rb:351:13:351:17 | call to foo | foo | 0 | calls.rb:351:17:351:17 | x | -| calls.rb:361:5:361:6 | call to == | == | 0 | calls.rb:361:1:361:4 | __synth__0__1 | -| calls.rb:363:1:363:23 | call to bar | bar | 0 | calls.rb:363:10:363:10 | 1 | -| calls.rb:363:1:363:23 | call to bar | bar | 0 | calls.rb:363:10:363:10 | 1 | -| calls.rb:363:1:363:23 | call to bar | bar | 1 | calls.rb:363:12:363:12 | 2 | -| calls.rb:363:1:363:23 | call to bar | bar | 1 | calls.rb:363:12:363:12 | 2 | -| calls.rb:363:4:363:5 | call to == | == | 0 | calls.rb:363:1:363:3 | __synth__0__1 | +| calls.rb:318:1:318:6 | call to []= | []= | 0 | calls.rb:318:5:318:5 | 0 | +| calls.rb:318:1:318:6 | call to []= | []= | 1 | calls.rb:318:10:318:11 | ... = ... | +| calls.rb:319:1:319:8 | call to [] | [] | 0 | calls.rb:319:1:319:8 | 0 | +| calls.rb:319:1:319:8 | call to foo= | foo= | 0 | calls.rb:319:1:319:8 | ... = ... | +| calls.rb:319:12:319:19 | call to [] | [] | 0 | calls.rb:319:12:319:19 | _ .. _ | +| calls.rb:319:12:319:19 | call to bar= | bar= | 0 | calls.rb:319:12:319:19 | ... = ... | +| calls.rb:319:22:319:27 | ...[...] | [] | 0 | calls.rb:319:26:319:26 | 4 | +| calls.rb:319:22:319:27 | call to [] | [] | 0 | calls.rb:319:22:319:27 | -1 | +| calls.rb:319:22:319:27 | call to [] | [] | 0 | calls.rb:319:26:319:26 | 4 | +| calls.rb:319:22:319:27 | call to []= | []= | 0 | calls.rb:319:26:319:26 | 4 | +| calls.rb:319:22:319:27 | call to []= | []= | 1 | calls.rb:319:22:319:27 | ... = ... | +| calls.rb:319:31:319:42 | call to [] | [] | 0 | calls.rb:319:32:319:32 | 1 | +| calls.rb:319:31:319:42 | call to [] | [] | 1 | calls.rb:319:35:319:35 | 2 | +| calls.rb:319:31:319:42 | call to [] | [] | 2 | calls.rb:319:38:319:38 | 3 | +| calls.rb:319:31:319:42 | call to [] | [] | 3 | calls.rb:319:41:319:41 | 4 | +| calls.rb:320:1:320:1 | call to [] | [] | 0 | calls.rb:320:1:320:1 | 0 | +| calls.rb:320:5:320:10 | ...[...] | [] | 0 | calls.rb:320:9:320:9 | 5 | +| calls.rb:320:5:320:10 | call to [] | [] | 0 | calls.rb:320:5:320:10 | _ .. _ | +| calls.rb:320:5:320:10 | call to [] | [] | 0 | calls.rb:320:9:320:9 | 5 | +| calls.rb:320:5:320:10 | call to []= | []= | 0 | calls.rb:320:9:320:9 | 5 | +| calls.rb:320:5:320:10 | call to []= | []= | 1 | calls.rb:320:5:320:10 | ... = ... | +| calls.rb:320:14:320:22 | call to [] | [] | 0 | calls.rb:320:15:320:15 | 1 | +| calls.rb:320:14:320:22 | call to [] | [] | 1 | calls.rb:320:18:320:18 | 2 | +| calls.rb:320:14:320:22 | call to [] | [] | 2 | calls.rb:320:21:320:21 | 3 | +| calls.rb:321:1:321:10 | call to count= | count= | 0 | calls.rb:321:1:321:10 | __synth__1 | +| calls.rb:321:12:321:13 | ... + ... | + | 0 | calls.rb:321:15:321:15 | 1 | +| calls.rb:322:1:322:6 | ...[...] | [] | 0 | calls.rb:322:5:322:5 | 0 | +| calls.rb:322:1:322:6 | call to [] | [] | 0 | calls.rb:322:5:322:5 | __synth__1 | +| calls.rb:322:1:322:6 | call to []= | []= | 0 | calls.rb:322:5:322:5 | __synth__1 | +| calls.rb:322:1:322:6 | call to []= | []= | 1 | calls.rb:322:1:322:6 | __synth__2 | +| calls.rb:322:8:322:9 | ... + ... | + | 0 | calls.rb:322:11:322:11 | 1 | +| calls.rb:323:1:323:32 | ...[...] | [] | 0 | calls.rb:323:9:323:9 | 0 | +| calls.rb:323:1:323:32 | ...[...] | [] | 1 | calls.rb:323:12:323:18 | call to baz | +| calls.rb:323:1:323:32 | ...[...] | [] | 2 | calls.rb:323:21:323:31 | ... + ... | +| calls.rb:323:1:323:32 | call to [] | [] | 0 | calls.rb:323:9:323:9 | __synth__1 | +| calls.rb:323:1:323:32 | call to [] | [] | 1 | calls.rb:323:12:323:18 | __synth__2 | +| calls.rb:323:1:323:32 | call to [] | [] | 2 | calls.rb:323:21:323:31 | __synth__3 | +| calls.rb:323:1:323:32 | call to []= | []= | 0 | calls.rb:323:9:323:9 | __synth__1 | +| calls.rb:323:1:323:32 | call to []= | []= | 1 | calls.rb:323:12:323:18 | __synth__2 | +| calls.rb:323:1:323:32 | call to []= | []= | 2 | calls.rb:323:21:323:31 | __synth__3 | +| calls.rb:323:1:323:32 | call to []= | []= | 3 | calls.rb:323:1:323:32 | __synth__4 | +| calls.rb:323:21:323:31 | ... + ... | + | 0 | calls.rb:323:31:323:31 | 1 | +| calls.rb:323:34:323:35 | ... * ... | * | 0 | calls.rb:323:37:323:37 | 2 | +| calls.rb:331:25:331:37 | call to print | print | 0 | calls.rb:331:31:331:37 | "error" | +| calls.rb:335:3:335:12 | super call to foo | foo | 0 | calls.rb:335:9:335:11 | ... | +| calls.rb:339:3:339:13 | call to bar | bar | 0 | calls.rb:339:7:339:7 | b | +| calls.rb:339:3:339:13 | call to bar | bar | 1 | calls.rb:339:10:339:12 | ... | +| calls.rb:343:5:343:5 | call to [] | [] | 0 | calls.rb:343:5:343:5 | 0 | +| calls.rb:343:8:343:8 | call to [] | [] | 0 | calls.rb:343:8:343:8 | 1 | +| calls.rb:343:11:343:11 | call to [] | [] | 0 | calls.rb:343:11:343:11 | 2 | +| calls.rb:343:16:343:33 | call to [] | [] | 0 | calls.rb:343:17:343:23 | [...] | +| calls.rb:343:16:343:33 | call to [] | [] | 1 | calls.rb:343:26:343:32 | [...] | +| calls.rb:343:17:343:23 | call to [] | [] | 0 | calls.rb:343:18:343:18 | 1 | +| calls.rb:343:17:343:23 | call to [] | [] | 1 | calls.rb:343:20:343:20 | 2 | +| calls.rb:343:17:343:23 | call to [] | [] | 2 | calls.rb:343:22:343:22 | 3 | +| calls.rb:343:26:343:32 | call to [] | [] | 0 | calls.rb:343:27:343:27 | 4 | +| calls.rb:343:26:343:32 | call to [] | [] | 1 | calls.rb:343:29:343:29 | 5 | +| calls.rb:343:26:343:32 | call to [] | [] | 2 | calls.rb:343:31:343:31 | 6 | +| calls.rb:344:3:344:13 | call to foo | foo | 0 | calls.rb:344:7:344:7 | x | +| calls.rb:344:3:344:13 | call to foo | foo | 1 | calls.rb:344:10:344:10 | y | +| calls.rb:344:3:344:13 | call to foo | foo | 2 | calls.rb:344:13:344:13 | z | +| calls.rb:347:1:347:10 | call to foo | foo | 0 | calls.rb:347:5:347:9 | Pair | +| calls.rb:348:1:348:15 | call to foo | foo | 0 | calls.rb:348:5:348:6 | Pair | +| calls.rb:348:1:348:15 | call to foo | foo | 1 | calls.rb:348:9:348:14 | Pair | +| calls.rb:349:1:349:10 | call to foo | foo | 0 | calls.rb:349:5:349:9 | Pair | +| calls.rb:350:1:350:7 | call to foo | foo | 0 | calls.rb:350:5:350:6 | Pair | +| calls.rb:355:13:355:17 | call to foo | foo | 0 | calls.rb:355:17:355:17 | x | +| calls.rb:365:5:365:6 | call to == | == | 0 | calls.rb:365:1:365:4 | __synth__0__1 | +| calls.rb:367:1:367:23 | call to bar | bar | 0 | calls.rb:367:10:367:10 | 1 | +| calls.rb:367:1:367:23 | call to bar | bar | 0 | calls.rb:367:10:367:10 | 1 | +| calls.rb:367:1:367:23 | call to bar | bar | 1 | calls.rb:367:12:367:12 | 2 | +| calls.rb:367:1:367:23 | call to bar | bar | 1 | calls.rb:367:12:367:12 | 2 | +| calls.rb:367:4:367:5 | call to == | == | 0 | calls.rb:367:1:367:3 | __synth__0__1 | callsWithReceiver | calls.rb:2:1:2:5 | call to foo | calls.rb:2:1:2:5 | self | | calls.rb:5:1:5:10 | call to bar | calls.rb:5:1:5:3 | Foo | @@ -282,135 +282,135 @@ callsWithReceiver | calls.rb:251:8:251:10 | call to bar | calls.rb:251:8:251:10 | self | | calls.rb:254:8:254:13 | call to foo | calls.rb:254:8:254:8 | X | | calls.rb:255:8:255:13 | call to bar | calls.rb:255:8:255:8 | X | -| calls.rb:259:1:259:3 | call to foo | calls.rb:259:1:259:3 | self | -| calls.rb:259:12:259:14 | call to bar | calls.rb:259:12:259:14 | self | -| calls.rb:260:1:260:6 | call to foo | calls.rb:260:1:260:1 | X | -| calls.rb:260:15:260:20 | call to bar | calls.rb:260:15:260:15 | X | -| calls.rb:263:1:263:9 | call to foo | calls.rb:263:1:263:9 | self | -| calls.rb:263:6:263:8 | call to bar | calls.rb:263:6:263:8 | self | -| calls.rb:264:1:264:12 | call to foo | calls.rb:264:1:264:12 | self | -| calls.rb:264:6:264:11 | call to bar | calls.rb:264:6:264:6 | X | -| calls.rb:265:1:265:6 | call to foo | calls.rb:265:1:265:6 | self | +| calls.rb:263:1:263:3 | call to foo | calls.rb:263:1:263:3 | self | +| calls.rb:263:12:263:14 | call to bar | calls.rb:263:12:263:14 | self | +| calls.rb:264:1:264:6 | call to foo | calls.rb:264:1:264:1 | X | +| calls.rb:264:15:264:20 | call to bar | calls.rb:264:15:264:15 | X | | calls.rb:267:1:267:9 | call to foo | calls.rb:267:1:267:9 | self | -| calls.rb:267:5:267:8 | * ... | calls.rb:267:6:267:8 | call to bar | | calls.rb:267:6:267:8 | call to bar | calls.rb:267:6:267:8 | self | | calls.rb:268:1:268:12 | call to foo | calls.rb:268:1:268:12 | self | -| calls.rb:268:5:268:11 | * ... | calls.rb:268:6:268:11 | call to bar | | calls.rb:268:6:268:11 | call to bar | calls.rb:268:6:268:6 | X | | calls.rb:269:1:269:6 | call to foo | calls.rb:269:1:269:6 | self | -| calls.rb:272:1:272:10 | call to foo | calls.rb:272:1:272:10 | self | -| calls.rb:272:5:272:9 | ** ... | calls.rb:272:7:272:9 | call to bar | -| calls.rb:272:7:272:9 | call to bar | calls.rb:272:7:272:9 | self | -| calls.rb:273:1:273:13 | call to foo | calls.rb:273:1:273:13 | self | -| calls.rb:273:5:273:12 | ** ... | calls.rb:273:7:273:12 | call to bar | -| calls.rb:273:7:273:12 | call to bar | calls.rb:273:7:273:7 | X | -| calls.rb:274:1:274:7 | call to foo | calls.rb:274:1:274:7 | self | -| calls.rb:277:1:277:14 | call to foo | calls.rb:277:1:277:14 | self | -| calls.rb:277:11:277:13 | call to bar | calls.rb:277:11:277:13 | self | -| calls.rb:278:1:278:17 | call to foo | calls.rb:278:1:278:17 | self | -| calls.rb:278:11:278:16 | call to bar | calls.rb:278:11:278:11 | X | -| calls.rb:289:17:289:21 | ... + ... | calls.rb:289:17:289:17 | x | -| calls.rb:290:18:290:22 | ... * ... | calls.rb:290:18:290:18 | x | -| calls.rb:291:22:291:28 | ... + ... | calls.rb:291:22:291:22 | x | -| calls.rb:292:23:292:29 | ... + ... | calls.rb:292:23:292:23 | x | -| calls.rb:302:5:302:7 | call to foo | calls.rb:302:5:302:7 | self | -| calls.rb:302:5:302:13 | call to super | calls.rb:302:5:302:7 | call to foo | -| calls.rb:303:5:303:14 | call to super | calls.rb:303:5:303:8 | self | -| calls.rb:304:5:304:15 | call to super | calls.rb:304:5:304:9 | super call to another_method | -| calls.rb:309:1:309:3 | call to foo | calls.rb:309:1:309:3 | self | -| calls.rb:309:1:309:6 | call to call | calls.rb:309:1:309:3 | call to foo | -| calls.rb:310:1:310:3 | call to foo | calls.rb:310:1:310:3 | self | -| calls.rb:310:1:310:7 | call to call | calls.rb:310:1:310:3 | call to foo | -| calls.rb:313:1:313:8 | call to foo | calls.rb:313:1:313:4 | self | -| calls.rb:313:1:313:8 | call to foo= | calls.rb:313:1:313:4 | self | +| calls.rb:271:1:271:9 | call to foo | calls.rb:271:1:271:9 | self | +| calls.rb:271:5:271:8 | * ... | calls.rb:271:6:271:8 | call to bar | +| calls.rb:271:6:271:8 | call to bar | calls.rb:271:6:271:8 | self | +| calls.rb:272:1:272:12 | call to foo | calls.rb:272:1:272:12 | self | +| calls.rb:272:5:272:11 | * ... | calls.rb:272:6:272:11 | call to bar | +| calls.rb:272:6:272:11 | call to bar | calls.rb:272:6:272:6 | X | +| calls.rb:273:1:273:6 | call to foo | calls.rb:273:1:273:6 | self | +| calls.rb:276:1:276:10 | call to foo | calls.rb:276:1:276:10 | self | +| calls.rb:276:5:276:9 | ** ... | calls.rb:276:7:276:9 | call to bar | +| calls.rb:276:7:276:9 | call to bar | calls.rb:276:7:276:9 | self | +| calls.rb:277:1:277:13 | call to foo | calls.rb:277:1:277:13 | self | +| calls.rb:277:5:277:12 | ** ... | calls.rb:277:7:277:12 | call to bar | +| calls.rb:277:7:277:12 | call to bar | calls.rb:277:7:277:7 | X | +| calls.rb:278:1:278:7 | call to foo | calls.rb:278:1:278:7 | self | +| calls.rb:281:1:281:14 | call to foo | calls.rb:281:1:281:14 | self | +| calls.rb:281:11:281:13 | call to bar | calls.rb:281:11:281:13 | self | +| calls.rb:282:1:282:17 | call to foo | calls.rb:282:1:282:17 | self | +| calls.rb:282:11:282:16 | call to bar | calls.rb:282:11:282:11 | X | +| calls.rb:293:17:293:21 | ... + ... | calls.rb:293:17:293:17 | x | +| calls.rb:294:18:294:22 | ... * ... | calls.rb:294:18:294:18 | x | +| calls.rb:295:22:295:28 | ... + ... | calls.rb:295:22:295:22 | x | +| calls.rb:296:23:296:29 | ... + ... | calls.rb:296:23:296:23 | x | +| calls.rb:306:5:306:7 | call to foo | calls.rb:306:5:306:7 | self | +| calls.rb:306:5:306:13 | call to super | calls.rb:306:5:306:7 | call to foo | +| calls.rb:307:5:307:14 | call to super | calls.rb:307:5:307:8 | self | +| calls.rb:308:5:308:15 | call to super | calls.rb:308:5:308:9 | super call to another_method | +| calls.rb:313:1:313:3 | call to foo | calls.rb:313:1:313:3 | self | +| calls.rb:313:1:313:6 | call to call | calls.rb:313:1:313:3 | call to foo | | calls.rb:314:1:314:3 | call to foo | calls.rb:314:1:314:3 | self | -| calls.rb:314:1:314:6 | ...[...] | calls.rb:314:1:314:3 | call to foo | -| calls.rb:314:1:314:6 | call to []= | calls.rb:314:1:314:3 | call to foo | -| calls.rb:315:1:315:8 | call to [] | calls.rb:315:1:315:8 | __synth__3 | -| calls.rb:315:1:315:8 | call to foo | calls.rb:315:1:315:4 | self | -| calls.rb:315:1:315:8 | call to foo | calls.rb:315:1:315:8 | __synth__0 | -| calls.rb:315:1:315:8 | call to foo= | calls.rb:315:1:315:8 | __synth__0 | -| calls.rb:315:12:315:19 | call to [] | calls.rb:315:12:315:19 | __synth__3 | -| calls.rb:315:12:315:19 | call to bar | calls.rb:315:12:315:15 | self | -| calls.rb:315:12:315:19 | call to bar | calls.rb:315:12:315:19 | __synth__1 | -| calls.rb:315:12:315:19 | call to bar= | calls.rb:315:12:315:19 | __synth__1 | -| calls.rb:315:22:315:24 | call to foo | calls.rb:315:22:315:24 | self | -| calls.rb:315:22:315:27 | ...[...] | calls.rb:315:22:315:24 | call to foo | -| calls.rb:315:22:315:27 | call to [] | calls.rb:315:22:315:27 | __synth__2 | -| calls.rb:315:22:315:27 | call to [] | calls.rb:315:22:315:27 | __synth__3 | -| calls.rb:315:22:315:27 | call to []= | calls.rb:315:22:315:27 | __synth__2 | -| calls.rb:315:31:315:42 | * ... | calls.rb:315:31:315:42 | [...] | -| calls.rb:315:31:315:42 | call to [] | calls.rb:315:31:315:42 | Array | -| calls.rb:316:1:316:1 | call to [] | calls.rb:316:1:316:1 | __synth__2 | -| calls.rb:316:5:316:7 | call to foo | calls.rb:316:5:316:7 | self | -| calls.rb:316:5:316:10 | ...[...] | calls.rb:316:5:316:7 | call to foo | -| calls.rb:316:5:316:10 | call to [] | calls.rb:316:5:316:10 | __synth__1 | -| calls.rb:316:5:316:10 | call to [] | calls.rb:316:5:316:10 | __synth__2 | -| calls.rb:316:5:316:10 | call to []= | calls.rb:316:5:316:10 | __synth__1 | -| calls.rb:316:14:316:22 | * ... | calls.rb:316:14:316:22 | [...] | -| calls.rb:316:14:316:22 | call to [] | calls.rb:316:14:316:22 | Array | -| calls.rb:317:1:317:10 | call to count | calls.rb:317:1:317:4 | __synth__0 | -| calls.rb:317:1:317:10 | call to count | calls.rb:317:1:317:4 | self | -| calls.rb:317:1:317:10 | call to count= | calls.rb:317:1:317:4 | __synth__0 | -| calls.rb:317:12:317:13 | ... + ... | calls.rb:317:1:317:10 | call to count | +| calls.rb:314:1:314:7 | call to call | calls.rb:314:1:314:3 | call to foo | +| calls.rb:317:1:317:8 | call to foo | calls.rb:317:1:317:4 | self | +| calls.rb:317:1:317:8 | call to foo= | calls.rb:317:1:317:4 | self | | calls.rb:318:1:318:3 | call to foo | calls.rb:318:1:318:3 | self | | calls.rb:318:1:318:6 | ...[...] | calls.rb:318:1:318:3 | call to foo | -| calls.rb:318:1:318:6 | call to [] | calls.rb:318:1:318:3 | __synth__0 | -| calls.rb:318:1:318:6 | call to []= | calls.rb:318:1:318:3 | __synth__0 | -| calls.rb:318:8:318:9 | ... + ... | calls.rb:318:1:318:6 | call to [] | -| calls.rb:319:1:319:3 | call to foo | calls.rb:319:1:319:3 | self | -| calls.rb:319:1:319:7 | call to bar | calls.rb:319:1:319:3 | call to foo | -| calls.rb:319:1:319:32 | ...[...] | calls.rb:319:1:319:7 | call to bar | -| calls.rb:319:1:319:32 | call to [] | calls.rb:319:1:319:7 | __synth__0 | -| calls.rb:319:1:319:32 | call to []= | calls.rb:319:1:319:7 | __synth__0 | -| calls.rb:319:12:319:14 | call to foo | calls.rb:319:12:319:14 | self | -| calls.rb:319:12:319:18 | call to baz | calls.rb:319:12:319:14 | call to foo | -| calls.rb:319:21:319:23 | call to foo | calls.rb:319:21:319:23 | self | -| calls.rb:319:21:319:27 | call to boo | calls.rb:319:21:319:23 | call to foo | -| calls.rb:319:21:319:31 | ... + ... | calls.rb:319:21:319:27 | call to boo | -| calls.rb:319:34:319:35 | ... * ... | calls.rb:319:1:319:32 | call to [] | -| calls.rb:322:11:322:13 | call to bar | calls.rb:322:11:322:13 | self | -| calls.rb:323:13:323:15 | call to bar | calls.rb:323:13:323:15 | self | -| calls.rb:324:14:324:16 | call to bar | calls.rb:324:14:324:16 | self | -| calls.rb:325:18:325:20 | call to bar | calls.rb:325:18:325:20 | self | -| calls.rb:326:22:326:24 | call to bar | calls.rb:326:22:326:24 | self | +| calls.rb:318:1:318:6 | call to []= | calls.rb:318:1:318:3 | call to foo | +| calls.rb:319:1:319:8 | call to [] | calls.rb:319:1:319:8 | __synth__3 | +| calls.rb:319:1:319:8 | call to foo | calls.rb:319:1:319:4 | self | +| calls.rb:319:1:319:8 | call to foo | calls.rb:319:1:319:8 | __synth__0 | +| calls.rb:319:1:319:8 | call to foo= | calls.rb:319:1:319:8 | __synth__0 | +| calls.rb:319:12:319:19 | call to [] | calls.rb:319:12:319:19 | __synth__3 | +| calls.rb:319:12:319:19 | call to bar | calls.rb:319:12:319:15 | self | +| calls.rb:319:12:319:19 | call to bar | calls.rb:319:12:319:19 | __synth__1 | +| calls.rb:319:12:319:19 | call to bar= | calls.rb:319:12:319:19 | __synth__1 | +| calls.rb:319:22:319:24 | call to foo | calls.rb:319:22:319:24 | self | +| calls.rb:319:22:319:27 | ...[...] | calls.rb:319:22:319:24 | call to foo | +| calls.rb:319:22:319:27 | call to [] | calls.rb:319:22:319:27 | __synth__2 | +| calls.rb:319:22:319:27 | call to [] | calls.rb:319:22:319:27 | __synth__3 | +| calls.rb:319:22:319:27 | call to []= | calls.rb:319:22:319:27 | __synth__2 | +| calls.rb:319:31:319:42 | * ... | calls.rb:319:31:319:42 | [...] | +| calls.rb:319:31:319:42 | call to [] | calls.rb:319:31:319:42 | Array | +| calls.rb:320:1:320:1 | call to [] | calls.rb:320:1:320:1 | __synth__2 | +| calls.rb:320:5:320:7 | call to foo | calls.rb:320:5:320:7 | self | +| calls.rb:320:5:320:10 | ...[...] | calls.rb:320:5:320:7 | call to foo | +| calls.rb:320:5:320:10 | call to [] | calls.rb:320:5:320:10 | __synth__1 | +| calls.rb:320:5:320:10 | call to [] | calls.rb:320:5:320:10 | __synth__2 | +| calls.rb:320:5:320:10 | call to []= | calls.rb:320:5:320:10 | __synth__1 | +| calls.rb:320:14:320:22 | * ... | calls.rb:320:14:320:22 | [...] | +| calls.rb:320:14:320:22 | call to [] | calls.rb:320:14:320:22 | Array | +| calls.rb:321:1:321:10 | call to count | calls.rb:321:1:321:4 | __synth__0 | +| calls.rb:321:1:321:10 | call to count | calls.rb:321:1:321:4 | self | +| calls.rb:321:1:321:10 | call to count= | calls.rb:321:1:321:4 | __synth__0 | +| calls.rb:321:12:321:13 | ... + ... | calls.rb:321:1:321:10 | call to count | +| calls.rb:322:1:322:3 | call to foo | calls.rb:322:1:322:3 | self | +| calls.rb:322:1:322:6 | ...[...] | calls.rb:322:1:322:3 | call to foo | +| calls.rb:322:1:322:6 | call to [] | calls.rb:322:1:322:3 | __synth__0 | +| calls.rb:322:1:322:6 | call to []= | calls.rb:322:1:322:3 | __synth__0 | +| calls.rb:322:8:322:9 | ... + ... | calls.rb:322:1:322:6 | call to [] | +| calls.rb:323:1:323:3 | call to foo | calls.rb:323:1:323:3 | self | +| calls.rb:323:1:323:7 | call to bar | calls.rb:323:1:323:3 | call to foo | +| calls.rb:323:1:323:32 | ...[...] | calls.rb:323:1:323:7 | call to bar | +| calls.rb:323:1:323:32 | call to [] | calls.rb:323:1:323:7 | __synth__0 | +| calls.rb:323:1:323:32 | call to []= | calls.rb:323:1:323:7 | __synth__0 | +| calls.rb:323:12:323:14 | call to foo | calls.rb:323:12:323:14 | self | +| calls.rb:323:12:323:18 | call to baz | calls.rb:323:12:323:14 | call to foo | +| calls.rb:323:21:323:23 | call to foo | calls.rb:323:21:323:23 | self | +| calls.rb:323:21:323:27 | call to boo | calls.rb:323:21:323:23 | call to foo | +| calls.rb:323:21:323:31 | ... + ... | calls.rb:323:21:323:27 | call to boo | +| calls.rb:323:34:323:35 | ... * ... | calls.rb:323:1:323:32 | call to [] | +| calls.rb:326:11:326:13 | call to bar | calls.rb:326:11:326:13 | self | | calls.rb:327:13:327:15 | call to bar | calls.rb:327:13:327:15 | self | -| calls.rb:327:25:327:37 | call to print | calls.rb:327:25:327:37 | self | -| calls.rb:335:3:335:13 | call to bar | calls.rb:335:3:335:13 | self | -| calls.rb:339:1:341:3 | * ... | calls.rb:339:1:341:3 | __synth__0__1 | -| calls.rb:339:1:341:3 | call to each | calls.rb:339:16:339:33 | [...] | -| calls.rb:339:5:339:5 | ! ... | calls.rb:339:5:339:5 | defined? ... | -| calls.rb:339:5:339:5 | call to [] | calls.rb:339:5:339:5 | __synth__3__1 | -| calls.rb:339:5:339:5 | defined? ... | calls.rb:339:5:339:5 | x | -| calls.rb:339:8:339:8 | ! ... | calls.rb:339:8:339:8 | defined? ... | -| calls.rb:339:8:339:8 | call to [] | calls.rb:339:8:339:8 | __synth__3__1 | -| calls.rb:339:8:339:8 | defined? ... | calls.rb:339:8:339:8 | y | -| calls.rb:339:11:339:11 | ! ... | calls.rb:339:11:339:11 | defined? ... | -| calls.rb:339:11:339:11 | call to [] | calls.rb:339:11:339:11 | __synth__3__1 | -| calls.rb:339:11:339:11 | defined? ... | calls.rb:339:11:339:11 | z | -| calls.rb:339:16:339:33 | call to [] | calls.rb:339:16:339:33 | Array | -| calls.rb:339:17:339:23 | call to [] | calls.rb:339:17:339:23 | Array | -| calls.rb:339:26:339:32 | call to [] | calls.rb:339:26:339:32 | Array | -| calls.rb:340:3:340:13 | call to foo | calls.rb:340:3:340:13 | self | -| calls.rb:343:1:343:10 | call to foo | calls.rb:343:1:343:10 | self | -| calls.rb:344:1:344:15 | call to foo | calls.rb:344:1:344:15 | self | -| calls.rb:345:1:345:10 | call to foo | calls.rb:345:1:345:10 | self | -| calls.rb:346:1:346:7 | call to foo | calls.rb:346:1:346:7 | self | -| calls.rb:351:13:351:17 | call to foo | calls.rb:351:13:351:17 | self | -| calls.rb:352:13:352:24 | call to unknown_call | calls.rb:352:13:352:24 | self | -| calls.rb:356:3:356:14 | call to unknown_call | calls.rb:356:3:356:14 | self | -| calls.rb:360:1:360:4 | call to list | calls.rb:360:1:360:4 | self | -| calls.rb:360:1:360:11 | call to empty? | calls.rb:360:1:360:4 | call to list | -| calls.rb:361:1:361:4 | call to list | calls.rb:361:1:361:4 | self | -| calls.rb:361:1:361:12 | call to empty? | calls.rb:361:1:361:4 | __synth__0__1 | -| calls.rb:361:1:361:12 | call to empty? | calls.rb:361:1:361:4 | call to list | -| calls.rb:361:5:361:6 | call to == | calls.rb:361:5:361:6 | nil | -| calls.rb:362:1:362:4 | call to list | calls.rb:362:1:362:4 | self | -| calls.rb:362:1:362:12 | call to empty? | calls.rb:362:1:362:4 | call to list | -| calls.rb:363:1:363:3 | call to foo | calls.rb:363:1:363:3 | self | -| calls.rb:363:1:363:23 | call to bar | calls.rb:363:1:363:3 | __synth__0__1 | -| calls.rb:363:1:363:23 | call to bar | calls.rb:363:1:363:3 | call to foo | -| calls.rb:363:4:363:5 | call to == | calls.rb:363:4:363:5 | nil | +| calls.rb:328:14:328:16 | call to bar | calls.rb:328:14:328:16 | self | +| calls.rb:329:18:329:20 | call to bar | calls.rb:329:18:329:20 | self | +| calls.rb:330:22:330:24 | call to bar | calls.rb:330:22:330:24 | self | +| calls.rb:331:13:331:15 | call to bar | calls.rb:331:13:331:15 | self | +| calls.rb:331:25:331:37 | call to print | calls.rb:331:25:331:37 | self | +| calls.rb:339:3:339:13 | call to bar | calls.rb:339:3:339:13 | self | +| calls.rb:343:1:345:3 | * ... | calls.rb:343:1:345:3 | __synth__0__1 | +| calls.rb:343:1:345:3 | call to each | calls.rb:343:16:343:33 | [...] | +| calls.rb:343:5:343:5 | ! ... | calls.rb:343:5:343:5 | defined? ... | +| calls.rb:343:5:343:5 | call to [] | calls.rb:343:5:343:5 | __synth__3__1 | +| calls.rb:343:5:343:5 | defined? ... | calls.rb:343:5:343:5 | x | +| calls.rb:343:8:343:8 | ! ... | calls.rb:343:8:343:8 | defined? ... | +| calls.rb:343:8:343:8 | call to [] | calls.rb:343:8:343:8 | __synth__3__1 | +| calls.rb:343:8:343:8 | defined? ... | calls.rb:343:8:343:8 | y | +| calls.rb:343:11:343:11 | ! ... | calls.rb:343:11:343:11 | defined? ... | +| calls.rb:343:11:343:11 | call to [] | calls.rb:343:11:343:11 | __synth__3__1 | +| calls.rb:343:11:343:11 | defined? ... | calls.rb:343:11:343:11 | z | +| calls.rb:343:16:343:33 | call to [] | calls.rb:343:16:343:33 | Array | +| calls.rb:343:17:343:23 | call to [] | calls.rb:343:17:343:23 | Array | +| calls.rb:343:26:343:32 | call to [] | calls.rb:343:26:343:32 | Array | +| calls.rb:344:3:344:13 | call to foo | calls.rb:344:3:344:13 | self | +| calls.rb:347:1:347:10 | call to foo | calls.rb:347:1:347:10 | self | +| calls.rb:348:1:348:15 | call to foo | calls.rb:348:1:348:15 | self | +| calls.rb:349:1:349:10 | call to foo | calls.rb:349:1:349:10 | self | +| calls.rb:350:1:350:7 | call to foo | calls.rb:350:1:350:7 | self | +| calls.rb:355:13:355:17 | call to foo | calls.rb:355:13:355:17 | self | +| calls.rb:356:13:356:24 | call to unknown_call | calls.rb:356:13:356:24 | self | +| calls.rb:360:3:360:14 | call to unknown_call | calls.rb:360:3:360:14 | self | +| calls.rb:364:1:364:4 | call to list | calls.rb:364:1:364:4 | self | +| calls.rb:364:1:364:11 | call to empty? | calls.rb:364:1:364:4 | call to list | +| calls.rb:365:1:365:4 | call to list | calls.rb:365:1:365:4 | self | +| calls.rb:365:1:365:12 | call to empty? | calls.rb:365:1:365:4 | __synth__0__1 | +| calls.rb:365:1:365:12 | call to empty? | calls.rb:365:1:365:4 | call to list | +| calls.rb:365:5:365:6 | call to == | calls.rb:365:5:365:6 | nil | +| calls.rb:366:1:366:4 | call to list | calls.rb:366:1:366:4 | self | +| calls.rb:366:1:366:12 | call to empty? | calls.rb:366:1:366:4 | call to list | +| calls.rb:367:1:367:3 | call to foo | calls.rb:367:1:367:3 | self | +| calls.rb:367:1:367:23 | call to bar | calls.rb:367:1:367:3 | __synth__0__1 | +| calls.rb:367:1:367:23 | call to bar | calls.rb:367:1:367:3 | call to foo | +| calls.rb:367:4:367:5 | call to == | calls.rb:367:4:367:5 | nil | callsWithBlock | calls.rb:14:1:14:17 | call to foo | calls.rb:14:5:14:17 | { ... } | | calls.rb:17:1:19:3 | call to foo | calls.rb:17:5:19:3 | do ... end | @@ -419,52 +419,52 @@ callsWithBlock | calls.rb:92:1:95:3 | call to foo | calls.rb:92:7:95:3 | do ... end | | calls.rb:223:1:225:3 | call to each | calls.rb:223:1:225:3 | { ... } | | calls.rb:226:1:228:3 | call to each | calls.rb:226:1:228:3 | { ... } | -| calls.rb:289:5:289:23 | super call to my_method | calls.rb:289:11:289:23 | { ... } | -| calls.rb:290:5:290:26 | super call to my_method | calls.rb:290:11:290:26 | do ... end | -| calls.rb:291:5:291:30 | super call to my_method | calls.rb:291:16:291:30 | { ... } | -| calls.rb:292:5:292:33 | super call to my_method | calls.rb:292:16:292:33 | do ... end | -| calls.rb:339:1:341:3 | call to each | calls.rb:339:1:341:3 | { ... } | -| calls.rb:363:1:363:23 | call to bar | calls.rb:363:15:363:23 | { ... } | -| calls.rb:363:1:363:23 | call to bar | calls.rb:363:15:363:23 | { ... } | +| calls.rb:293:5:293:23 | super call to my_method | calls.rb:293:11:293:23 | { ... } | +| calls.rb:294:5:294:26 | super call to my_method | calls.rb:294:11:294:26 | do ... end | +| calls.rb:295:5:295:30 | super call to my_method | calls.rb:295:16:295:30 | { ... } | +| calls.rb:296:5:296:33 | super call to my_method | calls.rb:296:16:296:33 | do ... end | +| calls.rb:343:1:345:3 | call to each | calls.rb:343:1:345:3 | { ... } | +| calls.rb:367:1:367:23 | call to bar | calls.rb:367:15:367:23 | { ... } | +| calls.rb:367:1:367:23 | call to bar | calls.rb:367:15:367:23 | { ... } | yieldCalls | calls.rb:28:3:28:7 | yield ... | | calls.rb:33:3:33:16 | yield ... | superCalls -| calls.rb:285:5:285:9 | super call to my_method | -| calls.rb:286:5:286:11 | super call to my_method | -| calls.rb:287:5:287:16 | super call to my_method | -| calls.rb:288:5:288:17 | super call to my_method | -| calls.rb:289:5:289:23 | super call to my_method | -| calls.rb:290:5:290:26 | super call to my_method | -| calls.rb:291:5:291:30 | super call to my_method | -| calls.rb:292:5:292:33 | super call to my_method | -| calls.rb:304:5:304:9 | super call to another_method | -| calls.rb:331:3:331:12 | super call to foo | +| calls.rb:289:5:289:9 | super call to my_method | +| calls.rb:290:5:290:11 | super call to my_method | +| calls.rb:291:5:291:16 | super call to my_method | +| calls.rb:292:5:292:17 | super call to my_method | +| calls.rb:293:5:293:23 | super call to my_method | +| calls.rb:294:5:294:26 | super call to my_method | +| calls.rb:295:5:295:30 | super call to my_method | +| calls.rb:296:5:296:33 | super call to my_method | +| calls.rb:308:5:308:9 | super call to another_method | +| calls.rb:335:3:335:12 | super call to foo | superCallsWithArguments -| calls.rb:287:5:287:16 | super call to my_method | 0 | calls.rb:287:11:287:16 | "blah" | -| calls.rb:288:5:288:17 | super call to my_method | 0 | calls.rb:288:11:288:11 | 1 | -| calls.rb:288:5:288:17 | super call to my_method | 1 | calls.rb:288:14:288:14 | 2 | -| calls.rb:288:5:288:17 | super call to my_method | 2 | calls.rb:288:17:288:17 | 3 | -| calls.rb:291:5:291:30 | super call to my_method | 0 | calls.rb:291:11:291:11 | 4 | -| calls.rb:291:5:291:30 | super call to my_method | 1 | calls.rb:291:14:291:14 | 5 | -| calls.rb:292:5:292:33 | super call to my_method | 0 | calls.rb:292:11:292:11 | 6 | -| calls.rb:292:5:292:33 | super call to my_method | 1 | calls.rb:292:14:292:14 | 7 | -| calls.rb:331:3:331:12 | super call to foo | 0 | calls.rb:331:9:331:11 | ... | +| calls.rb:291:5:291:16 | super call to my_method | 0 | calls.rb:291:11:291:16 | "blah" | +| calls.rb:292:5:292:17 | super call to my_method | 0 | calls.rb:292:11:292:11 | 1 | +| calls.rb:292:5:292:17 | super call to my_method | 1 | calls.rb:292:14:292:14 | 2 | +| calls.rb:292:5:292:17 | super call to my_method | 2 | calls.rb:292:17:292:17 | 3 | +| calls.rb:295:5:295:30 | super call to my_method | 0 | calls.rb:295:11:295:11 | 4 | +| calls.rb:295:5:295:30 | super call to my_method | 1 | calls.rb:295:14:295:14 | 5 | +| calls.rb:296:5:296:33 | super call to my_method | 0 | calls.rb:296:11:296:11 | 6 | +| calls.rb:296:5:296:33 | super call to my_method | 1 | calls.rb:296:14:296:14 | 7 | +| calls.rb:335:3:335:12 | super call to foo | 0 | calls.rb:335:9:335:11 | ... | superCallsWithBlock -| calls.rb:289:5:289:23 | super call to my_method | calls.rb:289:11:289:23 | { ... } | -| calls.rb:290:5:290:26 | super call to my_method | calls.rb:290:11:290:26 | do ... end | -| calls.rb:291:5:291:30 | super call to my_method | calls.rb:291:16:291:30 | { ... } | -| calls.rb:292:5:292:33 | super call to my_method | calls.rb:292:16:292:33 | do ... end | +| calls.rb:293:5:293:23 | super call to my_method | calls.rb:293:11:293:23 | { ... } | +| calls.rb:294:5:294:26 | super call to my_method | calls.rb:294:11:294:26 | do ... end | +| calls.rb:295:5:295:30 | super call to my_method | calls.rb:295:16:295:30 | { ... } | +| calls.rb:296:5:296:33 | super call to my_method | calls.rb:296:16:296:33 | do ... end | setterCalls -| calls.rb:313:1:313:8 | call to foo= | -| calls.rb:314:1:314:6 | call to []= | -| calls.rb:315:1:315:8 | call to foo= | -| calls.rb:315:12:315:19 | call to bar= | -| calls.rb:315:22:315:27 | call to []= | -| calls.rb:316:5:316:10 | call to []= | -| calls.rb:317:1:317:10 | call to count= | +| calls.rb:317:1:317:8 | call to foo= | | calls.rb:318:1:318:6 | call to []= | -| calls.rb:319:1:319:32 | call to []= | +| calls.rb:319:1:319:8 | call to foo= | +| calls.rb:319:12:319:19 | call to bar= | +| calls.rb:319:22:319:27 | call to []= | +| calls.rb:320:5:320:10 | call to []= | +| calls.rb:321:1:321:10 | call to count= | +| calls.rb:322:1:322:6 | call to []= | +| calls.rb:323:1:323:32 | call to []= | callsWithSafeNavigationOperator -| calls.rb:361:1:361:12 | call to empty? | -| calls.rb:363:1:363:23 | call to bar | +| calls.rb:365:1:365:12 | call to empty? | +| calls.rb:367:1:367:23 | call to bar | diff --git a/ruby/ql/test/library-tests/ast/calls/calls.rb b/ruby/ql/test/library-tests/ast/calls/calls.rb index 5f06377b049..32cc6979179 100644 --- a/ruby/ql/test/library-tests/ast/calls/calls.rb +++ b/ruby/ql/test/library-tests/ast/calls/calls.rb @@ -255,6 +255,10 @@ rescue X::foo ensure X::bar end + + + + # rescue-modifier body and handler foo rescue bar X::foo rescue X::bar @@ -360,4 +364,4 @@ end list.empty? list&.empty? list::empty? -foo&.bar(1,2) { |x| x } \ No newline at end of file +foo&.bar(1,2) { |x| x } From 65b4a4346b5c3e43bcaab269e7ebe04f8f33dded Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Fri, 19 Jun 2026 09:50:14 +0000 Subject: [PATCH 2/5] Add ExceptionList AST node for rescue clauses with 2+ exceptions --- .../2026-06-19-rescue-exception-list.md | 4 + ruby/ql/lib/codeql/ruby/ast/Expr.qll | 59 +++++++++- ruby/ql/lib/codeql/ruby/ast/internal/AST.qll | 7 +- ruby/ql/test/library-tests/ast/Ast.expected | 10 ++ .../library-tests/ast/TreeSitter.expected | 107 ++++++++++-------- .../library-tests/ast/calls/calls.expected | 3 + ruby/ql/test/library-tests/ast/calls/calls.rb | 8 +- 7 files changed, 145 insertions(+), 53 deletions(-) create mode 100644 ruby/ql/lib/change-notes/2026-06-19-rescue-exception-list.md diff --git a/ruby/ql/lib/change-notes/2026-06-19-rescue-exception-list.md b/ruby/ql/lib/change-notes/2026-06-19-rescue-exception-list.md new file mode 100644 index 00000000000..cc7770131ac --- /dev/null +++ b/ruby/ql/lib/change-notes/2026-06-19-rescue-exception-list.md @@ -0,0 +1,4 @@ +--- +category: breaking +--- +* When a `rescue` clause has two or more exception types, the exceptions are no longer direct children of the `RescueClause` node. Instead, a new `ExceptionList` AST node wraps the exceptions. Use `RescueClause.getExceptions()` to get the `ExceptionList` node, and `ExceptionList.getException(int n)` to access the individual exceptions. For `rescue` clauses with zero or one exception, the behavior is unchanged and `RescueClause.getException(int n)` continues to work as before. diff --git a/ruby/ql/lib/codeql/ruby/ast/Expr.qll b/ruby/ql/lib/codeql/ruby/ast/Expr.qll index a49cafa8299..e45c6310f29 100644 --- a/ruby/ql/lib/codeql/ruby/ast/Expr.qll +++ b/ruby/ql/lib/codeql/ruby/ast/Expr.qll @@ -280,6 +280,37 @@ class Pair extends Expr instanceof PairImpl { final override string getAPrimaryQlClass() { result = "Pair" } } +/** + * A list of exception types in a rescue clause. For example, the exception list + * `FirstError, SecondError` in: + * ```rb + * begin + * do_something + * rescue FirstError, SecondError => e + * handle_error(e) + * end + * ``` + * This node is only present when there are two or more exceptions in the list. + */ +class ExceptionList extends Expr, TExceptionList { + private Ruby::Exceptions g; + + ExceptionList() { this = TExceptionList(g) } + + final override string getAPrimaryQlClass() { result = "ExceptionList" } + + /** Gets the `n`th exception in this list. */ + final Expr getException(int n) { toGenerated(result) = g.getChild(n) } + + final override string toString() { result = "..., ..." } + + final override AstNode getAChild(string pred) { + result = super.getAChild(pred) + or + pred = "getException" and result = this.getException(_) + } +} + /** * A rescue clause. For example: * ```rb @@ -305,8 +336,16 @@ class RescueClause extends Expr, TRescueClause { * handle_error(e) * end * ``` + * When there are two or more exceptions, use `getExceptions()` to get the `ExceptionList` node. */ - final Expr getException(int n) { toGenerated(result) = g.getExceptions().getChild(n) } + final Expr getException(int n) { + // 0 or 1 exception: no ExceptionList node, access directly + not exists(this.getExceptions()) and + toGenerated(result) = g.getExceptions().getChild(n) + or + // 2+ exceptions: delegate through ExceptionList + result = this.getExceptions().getException(n) + } /** * Gets an exception to match, if any. For example `FirstError` or `SecondError` in: @@ -320,6 +359,19 @@ class RescueClause extends Expr, TRescueClause { */ final Expr getAnException() { result = this.getException(_) } + /** + * Gets the exception list node when there are two or more exceptions to match. For example, + * the exception list `FirstError, SecondError` in: + * ```rb + * begin + * do_something + * rescue FirstError, SecondError => e + * handle_error(e) + * end + * ``` + */ + final ExceptionList getExceptions() { result = TExceptionList(g.getExceptions()) } + /** * Gets the variable to which to assign the matched exception, if any. * For example `err` in: @@ -343,8 +395,13 @@ class RescueClause extends Expr, TRescueClause { final override AstNode getAChild(string pred) { result = super.getAChild(pred) or + // For 0 or 1 exceptions, exceptions are direct children + not exists(this.getExceptions()) and pred = "getException" and result = this.getException(_) or + // For 2+ exceptions, the ExceptionList node is the direct child + pred = "getExceptions" and result = this.getExceptions() + or pred = "getVariableExpr" and result = this.getVariableExpr() or pred = "getBody" and result = this.getBody() diff --git a/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll b/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll index 4b3535c490d..1faba695a93 100644 --- a/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll +++ b/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll @@ -155,6 +155,7 @@ private module Cached { TEndBlock(Ruby::EndBlock g) or TEnsure(Ruby::Ensure g) or TEqExpr(Ruby::Binary g) { g instanceof @ruby_binary_equalequal } or + TExceptionList(Ruby::Exceptions g) { strictcount(g.getChild(_)) > 1 } or TExponentExprReal(Ruby::Binary g) { g instanceof @ruby_binary_starstar } or TExponentExprSynth(Ast::AstNode parent, int i) { mkSynthChild(ExponentExprKind(), parent, i) } or TFalseLiteral(Ruby::False g) or @@ -375,7 +376,8 @@ private module Cached { TClassVariableAccessReal or TComplementExpr or TComplexLiteral or TDefinedExprReal or TDelimitedSymbolLiteral or TDestructuredLeftAssignment or TDestructuredParameter or TDivExprReal or TDo or TDoBlock or TElementReference or TElseReal or TElsif or TEmptyStmt or - TEncoding or TEndBlock or TEnsure or TEqExpr or TExponentExprReal or TFalseLiteral or + TEncoding or TEndBlock or TEnsure or TEqExpr or TExceptionList or TExponentExprReal or + TFalseLiteral or TFile or TFindPattern or TFloatLiteral or TForExpr or TForwardParameter or TForwardArgument or TGEExpr or TGTExpr or TGlobalVariableAccessReal or THashKeySymbolLiteral or THashLiteral or THashPattern or THashSplatExprReal or @@ -475,6 +477,7 @@ private module Cached { n = TEndBlock(result) or n = TEnsure(result) or n = TEqExpr(result) or + n = TExceptionList(result) or n = TExponentExprReal(result) or n = TFalseLiteral(result) or n = TFile(result) or @@ -765,7 +768,7 @@ class TExpr = TSelf or TArgumentList or TRescueClause or TRescueModifierExpr or TPair or TStringConcatenation or TCall or TBlockArgument or TConstantAccess or TControlExpr or TLiteral or TCallable or TVariableAccess or TStmtSequence or TOperation or TForwardArgument or TDestructuredLhsExpr or - TMatchPattern or TTestPattern; + TMatchPattern or TTestPattern or TExceptionList; class TSplatExpr = TSplatExprReal or TSplatExprSynth; diff --git a/ruby/ql/test/library-tests/ast/Ast.expected b/ruby/ql/test/library-tests/ast/Ast.expected index 341f4cf2cd3..f41104f9e74 100644 --- a/ruby/ql/test/library-tests/ast/Ast.expected +++ b/ruby/ql/test/library-tests/ast/Ast.expected @@ -445,6 +445,16 @@ calls/calls.rb: # 255| getEnsure: [StmtSequence] ensure ... # 255| getStmt: [MethodCall] call to bar # 255| getReceiver: [ConstantReadAccess] X +# 257| getStmt: [BeginExpr] begin ... +# 258| getRescue: [RescueClause] rescue ... +# 258| getExceptions: [ExceptionList] ..., ... +# 258| getException: [MethodCall] call to foo +# 258| getReceiver: [SelfVariableAccess] self +# 258| getException: [MethodCall] call to bar +# 258| getReceiver: [ConstantReadAccess] X +# 259| getEnsure: [StmtSequence] ensure ... +# 259| getStmt: [MethodCall] call to baz +# 259| getReceiver: [SelfVariableAccess] self # 263| getStmt: [RescueModifierExpr] ... rescue ... # 263| getBody: [MethodCall] call to foo # 263| getReceiver: [SelfVariableAccess] self diff --git a/ruby/ql/test/library-tests/ast/TreeSitter.expected b/ruby/ql/test/library-tests/ast/TreeSitter.expected index 49ebf74a90d..918a41fd035 100644 --- a/ruby/ql/test/library-tests/ast/TreeSitter.expected +++ b/ruby/ql/test/library-tests/ast/TreeSitter.expected @@ -715,11 +715,26 @@ calls/calls.rb: # 255| 1: [ReservedWord] :: # 255| 2: [Identifier] bar # 256| 3: [ReservedWord] end -# 263| 76: [RescueModifier] RescueModifier +# 257| 76: [Begin] Begin +# 257| 0: [ReservedWord] begin +# 258| 1: [Rescue] Rescue +# 258| 0: [ReservedWord] rescue +# 258| 1: [Exceptions] Exceptions +# 258| 0: [Identifier] foo +# 258| 1: [ReservedWord] , +# 258| 2: [Call] Call +# 258| 0: [Constant] X +# 258| 1: [ReservedWord] :: +# 258| 2: [Identifier] bar +# 259| 2: [Ensure] Ensure +# 259| 0: [ReservedWord] ensure +# 259| 1: [Identifier] baz +# 260| 3: [ReservedWord] end +# 263| 77: [RescueModifier] RescueModifier # 263| 0: [Identifier] foo # 263| 1: [ReservedWord] rescue # 263| 2: [Identifier] bar -# 264| 77: [RescueModifier] RescueModifier +# 264| 78: [RescueModifier] RescueModifier # 264| 0: [Call] Call # 264| 0: [Constant] X # 264| 1: [ReservedWord] :: @@ -729,7 +744,7 @@ calls/calls.rb: # 264| 0: [Constant] X # 264| 1: [ReservedWord] :: # 264| 2: [Identifier] bar -# 267| 78: [Call] Call +# 267| 79: [Call] Call # 267| 0: [Identifier] foo # 267| 1: [ArgumentList] ArgumentList # 267| 0: [ReservedWord] ( @@ -737,7 +752,7 @@ calls/calls.rb: # 267| 0: [ReservedWord] & # 267| 1: [Identifier] bar # 267| 2: [ReservedWord] ) -# 268| 79: [Call] Call +# 268| 80: [Call] Call # 268| 0: [Identifier] foo # 268| 1: [ArgumentList] ArgumentList # 268| 0: [ReservedWord] ( @@ -748,14 +763,14 @@ calls/calls.rb: # 268| 1: [ReservedWord] :: # 268| 2: [Identifier] bar # 268| 2: [ReservedWord] ) -# 269| 80: [Call] Call +# 269| 81: [Call] Call # 269| 0: [Identifier] foo # 269| 1: [ArgumentList] ArgumentList # 269| 0: [ReservedWord] ( # 269| 1: [BlockArgument] BlockArgument # 269| 0: [ReservedWord] & # 269| 2: [ReservedWord] ) -# 271| 81: [Call] Call +# 271| 82: [Call] Call # 271| 0: [Identifier] foo # 271| 1: [ArgumentList] ArgumentList # 271| 0: [ReservedWord] ( @@ -763,7 +778,7 @@ calls/calls.rb: # 271| 0: [ReservedWord] * # 271| 1: [Identifier] bar # 271| 2: [ReservedWord] ) -# 272| 82: [Call] Call +# 272| 83: [Call] Call # 272| 0: [Identifier] foo # 272| 1: [ArgumentList] ArgumentList # 272| 0: [ReservedWord] ( @@ -774,14 +789,14 @@ calls/calls.rb: # 272| 1: [ReservedWord] :: # 272| 2: [Identifier] bar # 272| 2: [ReservedWord] ) -# 273| 83: [Call] Call +# 273| 84: [Call] Call # 273| 0: [Identifier] foo # 273| 1: [ArgumentList] ArgumentList # 273| 0: [ReservedWord] ( # 273| 1: [SplatArgument] SplatArgument # 273| 0: [ReservedWord] * # 273| 2: [ReservedWord] ) -# 276| 84: [Call] Call +# 276| 85: [Call] Call # 276| 0: [Identifier] foo # 276| 1: [ArgumentList] ArgumentList # 276| 0: [ReservedWord] ( @@ -789,7 +804,7 @@ calls/calls.rb: # 276| 0: [ReservedWord] ** # 276| 1: [Identifier] bar # 276| 2: [ReservedWord] ) -# 277| 85: [Call] Call +# 277| 86: [Call] Call # 277| 0: [Identifier] foo # 277| 1: [ArgumentList] ArgumentList # 277| 0: [ReservedWord] ( @@ -800,14 +815,14 @@ calls/calls.rb: # 277| 1: [ReservedWord] :: # 277| 2: [Identifier] bar # 277| 2: [ReservedWord] ) -# 278| 86: [Call] Call +# 278| 87: [Call] Call # 278| 0: [Identifier] foo # 278| 1: [ArgumentList] ArgumentList # 278| 0: [ReservedWord] ( # 278| 1: [HashSplatArgument] HashSplatArgument # 278| 0: [ReservedWord] ** # 278| 2: [ReservedWord] ) -# 281| 87: [Call] Call +# 281| 88: [Call] Call # 281| 0: [Identifier] foo # 281| 1: [ArgumentList] ArgumentList # 281| 0: [ReservedWord] ( @@ -816,7 +831,7 @@ calls/calls.rb: # 281| 1: [ReservedWord] : # 281| 2: [Identifier] bar # 281| 2: [ReservedWord] ) -# 282| 88: [Call] Call +# 282| 89: [Call] Call # 282| 0: [Identifier] foo # 282| 1: [ArgumentList] ArgumentList # 282| 0: [ReservedWord] ( @@ -828,7 +843,7 @@ calls/calls.rb: # 282| 1: [ReservedWord] :: # 282| 2: [Identifier] bar # 282| 2: [ReservedWord] ) -# 287| 89: [Class] Class +# 287| 90: [Class] Class # 287| 0: [ReservedWord] class # 287| 1: [Constant] MyClass # 288| 2: [BodyStatement] BodyStatement @@ -923,7 +938,7 @@ calls/calls.rb: # 296| 3: [ReservedWord] end # 297| 3: [ReservedWord] end # 298| 3: [ReservedWord] end -# 304| 90: [Class] Class +# 304| 91: [Class] Class # 304| 0: [ReservedWord] class # 304| 1: [Constant] AnotherClass # 305| 2: [BodyStatement] BodyStatement @@ -945,27 +960,27 @@ calls/calls.rb: # 308| 2: [Identifier] super # 309| 3: [ReservedWord] end # 310| 3: [ReservedWord] end -# 313| 91: [Call] Call +# 313| 92: [Call] Call # 313| 0: [Identifier] foo # 313| 1: [ReservedWord] . # 313| 2: [ArgumentList] ArgumentList # 313| 0: [ReservedWord] ( # 313| 1: [ReservedWord] ) -# 314| 92: [Call] Call +# 314| 93: [Call] Call # 314| 0: [Identifier] foo # 314| 1: [ReservedWord] . # 314| 2: [ArgumentList] ArgumentList # 314| 0: [ReservedWord] ( # 314| 1: [Integer] 1 # 314| 2: [ReservedWord] ) -# 317| 93: [Assignment] Assignment +# 317| 94: [Assignment] Assignment # 317| 0: [Call] Call # 317| 0: [Self] self # 317| 1: [ReservedWord] . # 317| 2: [Identifier] foo # 317| 1: [ReservedWord] = # 317| 2: [Integer] 10 -# 318| 94: [Assignment] Assignment +# 318| 95: [Assignment] Assignment # 318| 0: [ElementReference] ElementReference # 318| 0: [Identifier] foo # 318| 1: [ReservedWord] [ @@ -973,7 +988,7 @@ calls/calls.rb: # 318| 3: [ReservedWord] ] # 318| 1: [ReservedWord] = # 318| 2: [Integer] 10 -# 319| 95: [Assignment] Assignment +# 319| 96: [Assignment] Assignment # 319| 0: [LeftAssignmentList] LeftAssignmentList # 319| 0: [Call] Call # 319| 0: [Self] self @@ -1003,7 +1018,7 @@ calls/calls.rb: # 319| 6: [ReservedWord] , # 319| 7: [Integer] 4 # 319| 8: [ReservedWord] ] -# 320| 96: [Assignment] Assignment +# 320| 97: [Assignment] Assignment # 320| 0: [LeftAssignmentList] LeftAssignmentList # 320| 0: [Identifier] a # 320| 1: [ReservedWord] , @@ -1023,14 +1038,14 @@ calls/calls.rb: # 320| 4: [ReservedWord] , # 320| 5: [Integer] 3 # 320| 6: [ReservedWord] ] -# 321| 97: [OperatorAssignment] OperatorAssignment +# 321| 98: [OperatorAssignment] OperatorAssignment # 321| 0: [Call] Call # 321| 0: [Self] self # 321| 1: [ReservedWord] . # 321| 2: [Identifier] count # 321| 1: [ReservedWord] += # 321| 2: [Integer] 1 -# 322| 98: [OperatorAssignment] OperatorAssignment +# 322| 99: [OperatorAssignment] OperatorAssignment # 322| 0: [ElementReference] ElementReference # 322| 0: [Identifier] foo # 322| 1: [ReservedWord] [ @@ -1038,7 +1053,7 @@ calls/calls.rb: # 322| 3: [ReservedWord] ] # 322| 1: [ReservedWord] += # 322| 2: [Integer] 1 -# 323| 99: [OperatorAssignment] OperatorAssignment +# 323| 100: [OperatorAssignment] OperatorAssignment # 323| 0: [ElementReference] ElementReference # 323| 0: [Call] Call # 323| 0: [Identifier] foo @@ -1062,12 +1077,12 @@ calls/calls.rb: # 323| 7: [ReservedWord] ] # 323| 1: [ReservedWord] *= # 323| 2: [Integer] 2 -# 326| 100: [Method] Method +# 326| 101: [Method] Method # 326| 0: [ReservedWord] def # 326| 1: [Identifier] foo # 326| 2: [ReservedWord] = # 326| 3: [Identifier] bar -# 327| 101: [Method] Method +# 327| 102: [Method] Method # 327| 0: [ReservedWord] def # 327| 1: [Identifier] foo # 327| 2: [MethodParameters] MethodParameters @@ -1075,7 +1090,7 @@ calls/calls.rb: # 327| 1: [ReservedWord] ) # 327| 3: [ReservedWord] = # 327| 4: [Identifier] bar -# 328| 102: [Method] Method +# 328| 103: [Method] Method # 328| 0: [ReservedWord] def # 328| 1: [Identifier] foo # 328| 2: [MethodParameters] MethodParameters @@ -1084,14 +1099,14 @@ calls/calls.rb: # 328| 2: [ReservedWord] ) # 328| 3: [ReservedWord] = # 328| 4: [Identifier] bar -# 329| 103: [SingletonMethod] SingletonMethod +# 329| 104: [SingletonMethod] SingletonMethod # 329| 0: [ReservedWord] def # 329| 1: [Constant] Object # 329| 2: [ReservedWord] . # 329| 3: [Identifier] foo # 329| 4: [ReservedWord] = # 329| 5: [Identifier] bar -# 330| 104: [SingletonMethod] SingletonMethod +# 330| 105: [SingletonMethod] SingletonMethod # 330| 0: [ReservedWord] def # 330| 1: [Constant] Object # 330| 2: [ReservedWord] . @@ -1102,7 +1117,7 @@ calls/calls.rb: # 330| 2: [ReservedWord] ) # 330| 5: [ReservedWord] = # 330| 6: [Identifier] bar -# 331| 105: [Method] Method +# 331| 106: [Method] Method # 331| 0: [ReservedWord] def # 331| 1: [Identifier] foo # 331| 2: [MethodParameters] MethodParameters @@ -1122,7 +1137,7 @@ calls/calls.rb: # 331| 1: [StringContent] error # 331| 2: [ReservedWord] " # 331| 2: [ReservedWord] ) -# 334| 106: [Method] Method +# 334| 107: [Method] Method # 334| 0: [ReservedWord] def # 334| 1: [Identifier] foo # 334| 2: [MethodParameters] MethodParameters @@ -1139,7 +1154,7 @@ calls/calls.rb: # 335| 0: [ReservedWord] ... # 335| 2: [ReservedWord] ) # 336| 4: [ReservedWord] end -# 338| 107: [Method] Method +# 338| 108: [Method] Method # 338| 0: [ReservedWord] def # 338| 1: [Identifier] foo # 338| 2: [MethodParameters] MethodParameters @@ -1162,7 +1177,7 @@ calls/calls.rb: # 339| 0: [ReservedWord] ... # 339| 4: [ReservedWord] ) # 340| 4: [ReservedWord] end -# 343| 108: [For] For +# 343| 109: [For] For # 343| 0: [ReservedWord] for # 343| 1: [LeftAssignmentList] LeftAssignmentList # 343| 0: [Identifier] x @@ -1202,7 +1217,7 @@ calls/calls.rb: # 344| 3: [ReservedWord] , # 344| 4: [Identifier] z # 345| 1: [ReservedWord] end -# 347| 109: [Call] Call +# 347| 110: [Call] Call # 347| 0: [Identifier] foo # 347| 1: [ArgumentList] ArgumentList # 347| 0: [ReservedWord] ( @@ -1211,7 +1226,7 @@ calls/calls.rb: # 347| 1: [ReservedWord] : # 347| 2: [Integer] 42 # 347| 2: [ReservedWord] ) -# 348| 110: [Call] Call +# 348| 111: [Call] Call # 348| 0: [Identifier] foo # 348| 1: [ArgumentList] ArgumentList # 348| 0: [ReservedWord] ( @@ -1223,7 +1238,7 @@ calls/calls.rb: # 348| 0: [HashKeySymbol] novar # 348| 1: [ReservedWord] : # 348| 4: [ReservedWord] ) -# 349| 111: [Call] Call +# 349| 112: [Call] Call # 349| 0: [Identifier] foo # 349| 1: [ArgumentList] ArgumentList # 349| 0: [ReservedWord] ( @@ -1232,7 +1247,7 @@ calls/calls.rb: # 349| 1: [ReservedWord] : # 349| 2: [Integer] 42 # 349| 2: [ReservedWord] ) -# 350| 112: [Call] Call +# 350| 113: [Call] Call # 350| 0: [Identifier] foo # 350| 1: [ArgumentList] ArgumentList # 350| 0: [ReservedWord] ( @@ -1240,11 +1255,11 @@ calls/calls.rb: # 350| 0: [HashKeySymbol] X # 350| 1: [ReservedWord] : # 350| 2: [ReservedWord] ) -# 353| 113: [Assignment] Assignment +# 353| 114: [Assignment] Assignment # 353| 0: [Identifier] y # 353| 1: [ReservedWord] = # 353| 2: [Integer] 1 -# 354| 114: [Assignment] Assignment +# 354| 115: [Assignment] Assignment # 354| 0: [Identifier] one # 354| 1: [ReservedWord] = # 354| 2: [Lambda] Lambda @@ -1258,7 +1273,7 @@ calls/calls.rb: # 354| 1: [BlockBody] BlockBody # 354| 0: [Identifier] y # 354| 2: [ReservedWord] } -# 355| 115: [Assignment] Assignment +# 355| 116: [Assignment] Assignment # 355| 0: [Identifier] f # 355| 1: [ReservedWord] = # 355| 2: [Lambda] Lambda @@ -1275,7 +1290,7 @@ calls/calls.rb: # 355| 1: [ArgumentList] ArgumentList # 355| 0: [Identifier] x # 355| 2: [ReservedWord] } -# 356| 116: [Assignment] Assignment +# 356| 117: [Assignment] Assignment # 356| 0: [Identifier] g # 356| 1: [ReservedWord] = # 356| 2: [Lambda] Lambda @@ -1289,7 +1304,7 @@ calls/calls.rb: # 356| 1: [BlockBody] BlockBody # 356| 0: [Identifier] unknown_call # 356| 2: [ReservedWord] } -# 357| 117: [Assignment] Assignment +# 357| 118: [Assignment] Assignment # 357| 0: [Identifier] h # 357| 1: [ReservedWord] = # 357| 2: [Lambda] Lambda @@ -1305,19 +1320,19 @@ calls/calls.rb: # 359| 1: [Identifier] y # 360| 2: [Identifier] unknown_call # 361| 2: [ReservedWord] end -# 364| 118: [Call] Call +# 364| 119: [Call] Call # 364| 0: [Identifier] list # 364| 1: [ReservedWord] . # 364| 2: [Identifier] empty? -# 365| 119: [Call] Call +# 365| 120: [Call] Call # 365| 0: [Identifier] list # 365| 1: [ReservedWord] &. # 365| 2: [Identifier] empty? -# 366| 120: [Call] Call +# 366| 121: [Call] Call # 366| 0: [Identifier] list # 366| 1: [ReservedWord] :: # 366| 2: [Identifier] empty? -# 367| 121: [Call] Call +# 367| 122: [Call] Call # 367| 0: [Identifier] foo # 367| 1: [ReservedWord] &. # 367| 2: [Identifier] bar diff --git a/ruby/ql/test/library-tests/ast/calls/calls.expected b/ruby/ql/test/library-tests/ast/calls/calls.expected index 4d9b7c9fdf8..a8c30218d24 100644 --- a/ruby/ql/test/library-tests/ast/calls/calls.expected +++ b/ruby/ql/test/library-tests/ast/calls/calls.expected @@ -282,6 +282,9 @@ callsWithReceiver | calls.rb:251:8:251:10 | call to bar | calls.rb:251:8:251:10 | self | | calls.rb:254:8:254:13 | call to foo | calls.rb:254:8:254:8 | X | | calls.rb:255:8:255:13 | call to bar | calls.rb:255:8:255:8 | X | +| calls.rb:258:8:258:10 | call to foo | calls.rb:258:8:258:10 | self | +| calls.rb:258:13:258:18 | call to bar | calls.rb:258:13:258:13 | X | +| calls.rb:259:8:259:10 | call to baz | calls.rb:259:8:259:10 | self | | calls.rb:263:1:263:3 | call to foo | calls.rb:263:1:263:3 | self | | calls.rb:263:12:263:14 | call to bar | calls.rb:263:12:263:14 | self | | calls.rb:264:1:264:6 | call to foo | calls.rb:264:1:264:1 | X | diff --git a/ruby/ql/test/library-tests/ast/calls/calls.rb b/ruby/ql/test/library-tests/ast/calls/calls.rb index 32cc6979179..34beb26ba03 100644 --- a/ruby/ql/test/library-tests/ast/calls/calls.rb +++ b/ruby/ql/test/library-tests/ast/calls/calls.rb @@ -254,10 +254,10 @@ begin rescue X::foo ensure X::bar end - - - - +begin +rescue foo, X::bar +ensure baz +end # rescue-modifier body and handler foo rescue bar From 132b476acdf10f401468d7b94b8764abcbdd07fc Mon Sep 17 00:00:00 2001 From: Anders Schack-Mulligen Date: Fri, 19 Jun 2026 13:08:20 +0200 Subject: [PATCH 3/5] Ruby: autoformat --- ruby/ql/lib/codeql/ruby/ast/Expr.qll | 3 ++- ruby/ql/lib/codeql/ruby/ast/internal/AST.qll | 3 +-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ruby/ql/lib/codeql/ruby/ast/Expr.qll b/ruby/ql/lib/codeql/ruby/ast/Expr.qll index e45c6310f29..b127dec6807 100644 --- a/ruby/ql/lib/codeql/ruby/ast/Expr.qll +++ b/ruby/ql/lib/codeql/ruby/ast/Expr.qll @@ -397,7 +397,8 @@ class RescueClause extends Expr, TRescueClause { or // For 0 or 1 exceptions, exceptions are direct children not exists(this.getExceptions()) and - pred = "getException" and result = this.getException(_) + pred = "getException" and + result = this.getException(_) or // For 2+ exceptions, the ExceptionList node is the direct child pred = "getExceptions" and result = this.getExceptions() diff --git a/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll b/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll index 1faba695a93..45e75000f65 100644 --- a/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll +++ b/ruby/ql/lib/codeql/ruby/ast/internal/AST.qll @@ -377,8 +377,7 @@ private module Cached { TDelimitedSymbolLiteral or TDestructuredLeftAssignment or TDestructuredParameter or TDivExprReal or TDo or TDoBlock or TElementReference or TElseReal or TElsif or TEmptyStmt or TEncoding or TEndBlock or TEnsure or TEqExpr or TExceptionList or TExponentExprReal or - TFalseLiteral or - TFile or TFindPattern or TFloatLiteral or TForExpr or TForwardParameter or + TFalseLiteral or TFile or TFindPattern or TFloatLiteral or TForExpr or TForwardParameter or TForwardArgument or TGEExpr or TGTExpr or TGlobalVariableAccessReal or THashKeySymbolLiteral or THashLiteral or THashPattern or THashSplatExprReal or THashSplatNilParameter or THashSplatParameter or THereDoc or TIdentifierMethodCall or From 6fbb5729507c58bc509dccff2dd63192306083fe Mon Sep 17 00:00:00 2001 From: Anders Schack-Mulligen Date: Fri, 19 Jun 2026 13:27:34 +0200 Subject: [PATCH 4/5] Ruby: Get rid of the change note. --- ruby/ql/lib/change-notes/2026-06-19-rescue-exception-list.md | 4 ---- 1 file changed, 4 deletions(-) delete mode 100644 ruby/ql/lib/change-notes/2026-06-19-rescue-exception-list.md diff --git a/ruby/ql/lib/change-notes/2026-06-19-rescue-exception-list.md b/ruby/ql/lib/change-notes/2026-06-19-rescue-exception-list.md deleted file mode 100644 index cc7770131ac..00000000000 --- a/ruby/ql/lib/change-notes/2026-06-19-rescue-exception-list.md +++ /dev/null @@ -1,4 +0,0 @@ ---- -category: breaking ---- -* When a `rescue` clause has two or more exception types, the exceptions are no longer direct children of the `RescueClause` node. Instead, a new `ExceptionList` AST node wraps the exceptions. Use `RescueClause.getExceptions()` to get the `ExceptionList` node, and `ExceptionList.getException(int n)` to access the individual exceptions. For `rescue` clauses with zero or one exception, the behavior is unchanged and `RescueClause.getException(int n)` continues to work as before. From 7d66ec0f3910a6e880d1690c2a38daa908b4654a Mon Sep 17 00:00:00 2001 From: Anders Schack-Mulligen Date: Mon, 22 Jun 2026 11:14:53 +0200 Subject: [PATCH 5/5] Ruby: Clarify AST. --- ruby/ql/lib/codeql/ruby/ast/Expr.qll | 39 ++++++++++++--------- ruby/ql/test/library-tests/ast/Ast.expected | 6 ++-- 2 files changed, 25 insertions(+), 20 deletions(-) diff --git a/ruby/ql/lib/codeql/ruby/ast/Expr.qll b/ruby/ql/lib/codeql/ruby/ast/Expr.qll index b127dec6807..fed7941f3ce 100644 --- a/ruby/ql/lib/codeql/ruby/ast/Expr.qll +++ b/ruby/ql/lib/codeql/ruby/ast/Expr.qll @@ -281,7 +281,7 @@ class Pair extends Expr instanceof PairImpl { } /** - * A list of exception types in a rescue clause. For example, the exception list + * A disjunctive exception pattern match in a rescue clause. For example, the exception list * `FirstError, SecondError` in: * ```rb * begin @@ -290,7 +290,6 @@ class Pair extends Expr instanceof PairImpl { * handle_error(e) * end * ``` - * This node is only present when there are two or more exceptions in the list. */ class ExceptionList extends Expr, TExceptionList { private Ruby::Exceptions g; @@ -327,16 +326,18 @@ class RescueClause extends Expr, TRescueClause { final override string getAPrimaryQlClass() { result = "RescueClause" } + /** Gets the exception list pattern when there are multiple exception expressions. */ + private ExceptionList getExceptions() { result = TExceptionList(g.getExceptions()) } + /** * Gets the `n`th exception to match, if any. For example `FirstError` or `SecondError` in: * ```rb * begin - * do_something + * do_something * rescue FirstError, SecondError => e * handle_error(e) * end * ``` - * When there are two or more exceptions, use `getExceptions()` to get the `ExceptionList` node. */ final Expr getException(int n) { // 0 or 1 exception: no ExceptionList node, access directly @@ -351,7 +352,7 @@ class RescueClause extends Expr, TRescueClause { * Gets an exception to match, if any. For example `FirstError` or `SecondError` in: * ```rb * begin - * do_something + * do_something * rescue FirstError, SecondError => e * handle_error(e) * end @@ -360,24 +361,34 @@ class RescueClause extends Expr, TRescueClause { final Expr getAnException() { result = this.getException(_) } /** - * Gets the exception list node when there are two or more exceptions to match. For example, - * the exception list `FirstError, SecondError` in: + * Gets the exception pattern to match, if any. + * + * This is either a single exception expression, or an `ExceptionList` + * representing a disjunctive match of multiple exceptions when there are two + * or more exceptions expressions. + * + * For example, in the following code, the exception pattern is the + * exception list `FirstError, SecondError`: * ```rb * begin - * do_something + * do_something * rescue FirstError, SecondError => e * handle_error(e) * end * ``` */ - final ExceptionList getExceptions() { result = TExceptionList(g.getExceptions()) } + final Expr getPattern() { + result = this.getExceptions() + or + not exists(this.getExceptions()) and result = this.getAnException() + } /** * Gets the variable to which to assign the matched exception, if any. * For example `err` in: * ```rb * begin - * do_something + * do_something * rescue StandardError => err * handle_error(err) * end @@ -395,13 +406,7 @@ class RescueClause extends Expr, TRescueClause { final override AstNode getAChild(string pred) { result = super.getAChild(pred) or - // For 0 or 1 exceptions, exceptions are direct children - not exists(this.getExceptions()) and - pred = "getException" and - result = this.getException(_) - or - // For 2+ exceptions, the ExceptionList node is the direct child - pred = "getExceptions" and result = this.getExceptions() + pred = "getPattern" and result = this.getPattern() or pred = "getVariableExpr" and result = this.getVariableExpr() or diff --git a/ruby/ql/test/library-tests/ast/Ast.expected b/ruby/ql/test/library-tests/ast/Ast.expected index f41104f9e74..8743b87f612 100644 --- a/ruby/ql/test/library-tests/ast/Ast.expected +++ b/ruby/ql/test/library-tests/ast/Ast.expected @@ -433,21 +433,21 @@ calls/calls.rb: # 246| getReceiver: [ConstantReadAccess] X # 249| getStmt: [BeginExpr] begin ... # 250| getRescue: [RescueClause] rescue ... -# 250| getException: [MethodCall] call to foo +# 250| getPattern: [MethodCall] call to foo # 250| getReceiver: [SelfVariableAccess] self # 251| getEnsure: [StmtSequence] ensure ... # 251| getStmt: [MethodCall] call to bar # 251| getReceiver: [SelfVariableAccess] self # 253| getStmt: [BeginExpr] begin ... # 254| getRescue: [RescueClause] rescue ... -# 254| getException: [MethodCall] call to foo +# 254| getPattern: [MethodCall] call to foo # 254| getReceiver: [ConstantReadAccess] X # 255| getEnsure: [StmtSequence] ensure ... # 255| getStmt: [MethodCall] call to bar # 255| getReceiver: [ConstantReadAccess] X # 257| getStmt: [BeginExpr] begin ... # 258| getRescue: [RescueClause] rescue ... -# 258| getExceptions: [ExceptionList] ..., ... +# 258| getPattern: [ExceptionList] ..., ... # 258| getException: [MethodCall] call to foo # 258| getReceiver: [SelfVariableAccess] self # 258| getException: [MethodCall] call to bar