@@ -920,187 +920,190 @@ control/cases.rb:
920920# 88| getPattern: [VariableReferencePattern] ^...
921921# 88| getVariableAccess: [LocalVariableAccess] foo
922922# 89| getBranch: [InClause] in ... then ...
923- # 89| getPattern: [LocalVariableAccess] var
923+ # 89| getPattern: [StringLiteral] "string"
924+ # 89| getComponent: [StringTextComponent] string
924925# 90| getBranch: [InClause] in ... then ...
925- # 90| getPattern: [StringLiteral] "string"
926- # 90| getComponent: [StringTextComponent] string
926+ # 90| getPattern: [ArrayLiteral] %w(...)
927+ # 90| getElement: [StringLiteral] "foo"
928+ # 90| getComponent: [StringTextComponent] foo
929+ # 90| getElement: [StringLiteral] "bar"
930+ # 90| getComponent: [StringTextComponent] bar
927931# 91| getBranch: [InClause] in ... then ...
928- # 91| getPattern: [ArrayLiteral] %w (...)
929- # 91| getElement: [StringLiteral] "foo"
932+ # 91| getPattern: [ArrayLiteral] %i (...)
933+ # 91| getElement: [SymbolLiteral] : "foo"
930934# 91| getComponent: [StringTextComponent] foo
931- # 91| getElement: [StringLiteral] "bar"
935+ # 91| getElement: [SymbolLiteral] : "bar"
932936# 91| getComponent: [StringTextComponent] bar
933937# 92| getBranch: [InClause] in ... then ...
934- # 92| getPattern: [ArrayLiteral] %i(...)
935- # 92| getElement: [SymbolLiteral] :"foo"
936- # 92| getComponent: [StringTextComponent] foo
937- # 92| getElement: [SymbolLiteral] :"bar"
938- # 92| getComponent: [StringTextComponent] bar
938+ # 92| getPattern: [RegExpLiteral] /.*abc[0-9]/
939+ # 92| getParsed: [RegExpSequence] .*abc[0-9]
940+ # 92| 0: [RegExpStar] .*
941+ # 92| 0: [RegExpDot] .
942+ # 92| 1: [RegExpConstant, RegExpNormalChar] a
943+ # 92| 2: [RegExpConstant, RegExpNormalChar] b
944+ # 92| 3: [RegExpConstant, RegExpNormalChar] c
945+ # 92| 4: [RegExpCharacterClass] [0-9]
946+ # 92| 0: [RegExpCharacterRange] 0-9
947+ # 92| 0: [RegExpConstant, RegExpNormalChar] 0
948+ # 92| 1: [RegExpConstant, RegExpNormalChar] 9
949+ # 92| getComponent: [StringTextComponent] .*abc[0-9]
939950# 93| getBranch: [InClause] in ... then ...
940- # 93| getPattern: [RegExpLiteral] /.*abc[0-9]/
941- # 93| getParsed: [RegExpSequence] .*abc[0-9]
942- # 93| 0: [RegExpStar] .*
943- # 93| 0: [RegExpDot] .
944- # 93| 1: [RegExpConstant, RegExpNormalChar] a
945- # 93| 2: [RegExpConstant, RegExpNormalChar] b
946- # 93| 3: [RegExpConstant, RegExpNormalChar] c
947- # 93| 4: [RegExpCharacterClass] [0-9]
948- # 93| 0: [RegExpCharacterRange] 0-9
949- # 93| 0: [RegExpConstant, RegExpNormalChar] 0
950- # 93| 1: [RegExpConstant, RegExpNormalChar] 9
951- # 93| getComponent: [StringTextComponent] .*abc[0-9]
951+ # 93| getPattern: [RangeLiteral] _ .. _
952+ # 93| getBegin: [IntegerLiteral] 5
953+ # 93| getEnd: [IntegerLiteral] 10
952954# 94| getBranch: [InClause] in ... then ...
953955# 94| getPattern: [RangeLiteral] _ .. _
954- # 94| getBegin: [IntegerLiteral] 5
955956# 94| getEnd: [IntegerLiteral] 10
956957# 95| getBranch: [InClause] in ... then ...
957958# 95| getPattern: [RangeLiteral] _ .. _
958- # 95| getEnd : [IntegerLiteral] 10
959+ # 95| getBegin : [IntegerLiteral] 5
959960# 96| getBranch: [InClause] in ... then ...
960- # 96| getPattern: [RangeLiteral] _ .. _
961- # 96| getBegin: [IntegerLiteral] 5
961+ # 96| getPattern: [AsPattern] ... => ...
962+ # 96| getPattern: [IntegerLiteral] 5
963+ # 96| getVariableAccess: [LocalVariableAccess] x
962964# 97| getBranch: [InClause] in ... then ...
963- # 97| getPattern: [AsPattern] ... => ...
964- # 97| getPattern: [IntegerLiteral] 5
965- # 97| getVariableAccess: [LocalVariableAccess] x
965+ # 97| getPattern: [ConstantReadAccess] Foo
966966# 98| getBranch: [InClause] in ... then ...
967- # 98| getPattern: [AlternativePattern] ... | ...
968- # 98| getAlternative: [IntegerLiteral] 5
969- # 98| getAlternative: [VariableReferencePattern] ^...
970- # 98| getVariableAccess: [LocalVariableAccess] foo
971- # 98| getAlternative: [LocalVariableAccess] var
972- # 98| getAlternative: [StringLiteral] "string"
973- # 98| getComponent: [StringTextComponent] string
967+ # 98| getPattern: [ConstantReadAccess] Bar
968+ # 98| getScopeExpr: [ConstantReadAccess] Foo
974969# 99| getBranch: [InClause] in ... then ...
975- # 99| getPattern: [ConstantReadAccess] Foo
970+ # 99| getPattern: [ConstantReadAccess] Bar
971+ # 99| getScopeExpr: [ConstantReadAccess] Foo
976972# 100| getBranch: [InClause] in ... then ...
977- # 100| getPattern: [ConstantReadAccess] Bar
978- # 100| getScopeExpr: [ConstantReadAccess] Foo
973+ # 100| getPattern: [AlternativePattern] ... | ...
974+ # 100| getAlternative: [NilLiteral] nil
975+ # 100| getAlternative: [Self, SelfVariableAccess] self
976+ # 100| getAlternative: [BooleanLiteral] true
977+ # 100| getAlternative: [BooleanLiteral] false
978+ # 100| getAlternative: [LineLiteral] __LINE__
979+ # 100| getAlternative: [FileLiteral] __FILE__
980+ # 100| getAlternative: [EncodingLiteral] __ENCODING__
979981# 101| getBranch: [InClause] in ... then ...
980- # 101| getPattern: [ConstantReadAccess] Bar
981- # 101| getScopeExpr: [ConstantReadAccess] Foo
982+ # 101| getPattern: [Lambda] -> { ... }
983+ # 101| getParameter: [SimpleParameter] x
984+ # 101| getDefiningAccess: [LocalVariableAccess] x
985+ # 101| getStmt: [EqExpr] ... == ...
986+ # 101| getAnOperand/getLeftOperand/getReceiver: [LocalVariableAccess] x
987+ # 101| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 10
982988# 102| getBranch: [InClause] in ... then ...
983- # 102| getPattern: [AlternativePattern] ... | ...
984- # 102| getAlternative: [NilLiteral] nil
985- # 102| getAlternative: [Self, SelfVariableAccess] self
986- # 102| getAlternative: [BooleanLiteral] true
987- # 102| getAlternative: [BooleanLiteral] false
988- # 102| getAlternative: [LineLiteral] __LINE__
989- # 102| getAlternative: [FileLiteral] __FILE__
990- # 102| getAlternative: [EncodingLiteral] __ENCODING__
989+ # 102| getPattern: [SymbolLiteral] :foo
991990# 103| getBranch: [InClause] in ... then ...
992- # 103| getPattern: [Lambda] -> { ... }
993- # 103| getParameter: [SimpleParameter] x
994- # 103| getDefiningAccess: [LocalVariableAccess] x
995- # 103| getStmt: [EqExpr] ... == ...
996- # 103| getAnOperand/getLeftOperand/getReceiver: [LocalVariableAccess] x
997- # 103| getAnOperand/getArgument/getRightOperand: [IntegerLiteral] 10
991+ # 103| getPattern: [SymbolLiteral] :"foo bar"
992+ # 103| getComponent: [StringTextComponent] foo bar
998993# 104| getBranch: [InClause] in ... then ...
999- # 104| getPattern: [SymbolLiteral] :foo
994+ # 104| getPattern: [AlternativePattern] ... | ...
995+ # 104| getAlternative: [UnaryMinusExpr] - ...
996+ # 104| getAnOperand/getOperand/getReceiver: [IntegerLiteral] 5
997+ # 104| getAlternative: [UnaryPlusExpr] + ...
998+ # 104| getAnOperand/getOperand/getReceiver: [IntegerLiteral] 10
1000999# 105| getBranch: [InClause] in ... then ...
1001- # 105| getPattern: [SymbolLiteral] :"foo bar"
1002- # 105| getComponent: [StringTextComponent] foo bar
1000+ # 105| getPattern: [ParenthesizedPattern] ( ... )
1001+ # 105| getPattern: [RangeLiteral] _ .. _
1002+ # 105| getBegin: [IntegerLiteral] 1
10031003# 106| getBranch: [InClause] in ... then ...
1004- # 106| getPattern: [AlternativePattern] ... | ...
1005- # 106| getAlternative: [UnaryMinusExpr] - ...
1006- # 106| getAnOperand/getOperand/getReceiver: [IntegerLiteral] 5
1007- # 106| getAlternative: [UnaryPlusExpr] + ...
1008- # 106| getAnOperand/getOperand/getReceiver: [IntegerLiteral] 10
1004+ # 106| getPattern: [ParenthesizedPattern] ( ... )
1005+ # 106| getPattern: [AlternativePattern] ... | ...
1006+ # 106| getAlternative: [IntegerLiteral] 0
1007+ # 106| getAlternative: [StringLiteral] ""
1008+ # 106| getAlternative: [ArrayPattern] [ ..., * ]
1009+ # 106| getAlternative: [HashPattern] { ..., ** }
10091010# 107| getBranch: [InClause] in ... then ...
1010- # 107| getPattern: [ParenthesizedPattern] ( ... )
1011- # 107| getPattern: [RangeLiteral] _ .. _
1012- # 107| getBegin: [IntegerLiteral] 1
1013- # 108| getBranch: [InClause] in ... then ...
1014- # 108| getPattern: [ParenthesizedPattern] ( ... )
1015- # 108| getPattern: [AlternativePattern] ... | ...
1016- # 108| getAlternative: [IntegerLiteral] 0
1017- # 108| getAlternative: [StringLiteral] ""
1018- # 108| getAlternative: [ArrayPattern] [ ..., * ]
1019- # 108| getAlternative: [HashPattern] { ..., ** }
1020- # 113| getStmt: [CaseExpr] case ...
1021- # 113| getValue: [MethodCall] call to expr
1022- # 113| getReceiver: [Self, SelfVariableAccess] self
1023- # 114| getBranch: [InClause] in ... then ...
1024- # 114| getPattern: [ArrayPattern] [ ..., * ]
1025- # 115| getBranch: [InClause] in ... then ...
1026- # 115| getPattern: [ArrayPattern] [ ..., * ]
1027- # 115| getPrefixElement: [LocalVariableAccess] x
1028- # 116| getBranch: [InClause] in ... then ...
1029- # 116| getPattern: [ArrayPattern] [ ..., * ]
1030- # 116| getPrefixElement/getSuffixElement: [LocalVariableAccess] x
1011+ # 107| getPattern: [LocalVariableAccess] var
1012+ # 110| getStmt: [CaseExpr] case ...
1013+ # 110| getValue: [MethodCall] call to expr
1014+ # 110| getReceiver: [Self, SelfVariableAccess] self
1015+ # 111| getBranch: [InClause] in ... then ...
1016+ # 111| getPattern: [AlternativePattern] ... | ...
1017+ # 111| getAlternative: [IntegerLiteral] 5
1018+ # 111| getAlternative: [VariableReferencePattern] ^...
1019+ # 111| getVariableAccess: [LocalVariableAccess] foo
1020+ # 111| getAlternative: [StringLiteral] "string"
1021+ # 111| getComponent: [StringTextComponent] string
1022+ # 111| getAlternative: [LocalVariableAccess] var
1023+ # 116| getStmt: [CaseExpr] case ...
1024+ # 116| getValue: [MethodCall] call to expr
1025+ # 116| getReceiver: [Self, SelfVariableAccess] self
10311026# 117| getBranch: [InClause] in ... then ...
10321027# 117| getPattern: [ArrayPattern] [ ..., * ]
1033- # 117| getClass: [ConstantReadAccess] Bar
1034- # 117| getScopeExpr: [ConstantReadAccess] Foo
10351028# 118| getBranch: [InClause] in ... then ...
10361029# 118| getPattern: [ArrayPattern] [ ..., * ]
1037- # 118| getClass : [ConstantReadAccess] Foo
1030+ # 118| getPrefixElement : [LocalVariableAccess] x
10381031# 119| getBranch: [InClause] in ... then ...
10391032# 119| getPattern: [ArrayPattern] [ ..., * ]
1040- # 119| getClass : [ConstantReadAccess] Bar
1033+ # 119| getPrefixElement/getSuffixElement : [LocalVariableAccess] x
10411034# 120| getBranch: [InClause] in ... then ...
10421035# 120| getPattern: [ArrayPattern] [ ..., * ]
10431036# 120| getClass: [ConstantReadAccess] Bar
1044- # 120| getPrefixElement/getSuffixElement: [LocalVariableAccess] a
1045- # 120| getPrefixElement/getSuffixElement: [LocalVariableAccess] b
1046- # 120| getRestVariableAccess: [LocalVariableAccess] c
1047- # 120| getSuffixElement: [LocalVariableAccess] d
1048- # 120| getSuffixElement: [LocalVariableAccess] e
1049- # 125| getStmt: [CaseExpr] case ...
1050- # 125| getValue: [MethodCall] call to expr
1051- # 125| getReceiver: [Self, SelfVariableAccess] self
1052- # 126| getBranch: [InClause] in ... then ...
1053- # 126| getPattern: [FindPattern] [ *,...,* ]
1054- # 126| getElement: [LocalVariableAccess] x
1055- # 127| getBranch: [InClause] in ... then ...
1056- # 127| getPattern: [FindPattern] [ *,...,* ]
1057- # 127| getPrefixVariableAccess: [LocalVariableAccess] x
1058- # 127| getElement: [IntegerLiteral] 1
1059- # 127| getElement: [IntegerLiteral] 2
1060- # 127| getSuffixVariableAccess: [LocalVariableAccess] y
1061- # 128| getBranch: [InClause] in ... then ...
1062- # 128| getPattern: [FindPattern] [ *,...,* ]
1063- # 128| getClass: [ConstantReadAccess] Bar
1064- # 128| getScopeExpr: [ConstantReadAccess] Foo
1065- # 128| getElement: [IntegerLiteral] 1
1037+ # 120| getScopeExpr: [ConstantReadAccess] Foo
1038+ # 121| getBranch: [InClause] in ... then ...
1039+ # 121| getPattern: [ArrayPattern] [ ..., * ]
1040+ # 121| getClass: [ConstantReadAccess] Foo
1041+ # 122| getBranch: [InClause] in ... then ...
1042+ # 122| getPattern: [ArrayPattern] [ ..., * ]
1043+ # 122| getClass: [ConstantReadAccess] Bar
1044+ # 123| getBranch: [InClause] in ... then ...
1045+ # 123| getPattern: [ArrayPattern] [ ..., * ]
1046+ # 123| getClass: [ConstantReadAccess] Bar
1047+ # 123| getPrefixElement/getSuffixElement: [LocalVariableAccess] a
1048+ # 123| getPrefixElement/getSuffixElement: [LocalVariableAccess] b
1049+ # 123| getRestVariableAccess: [LocalVariableAccess] c
1050+ # 123| getSuffixElement: [LocalVariableAccess] d
1051+ # 123| getSuffixElement: [LocalVariableAccess] e
1052+ # 128| getStmt: [CaseExpr] case ...
1053+ # 128| getValue: [MethodCall] call to expr
1054+ # 128| getReceiver: [Self, SelfVariableAccess] self
10661055# 129| getBranch: [InClause] in ... then ...
10671056# 129| getPattern: [FindPattern] [ *,...,* ]
1068- # 129| getClass: [ConstantReadAccess] Foo
1069- # 129| getElement: [ConstantReadAccess] Bar
1070- # 134| getStmt: [CaseExpr] case ...
1071- # 134| getValue: [MethodCall] call to expr
1072- # 134| getReceiver: [Self, SelfVariableAccess] self
1073- # 135| getBranch: [InClause] in ... then ...
1074- # 135| getPattern: [HashPattern] { ..., ** }
1075- # 136| getBranch: [InClause] in ... then ...
1076- # 136| getPattern: [HashPattern] { ..., ** }
1077- # 136| getKey: [SymbolLiteral] :x
1078- # 137| getBranch: [InClause] in ... then ...
1079- # 137| getPattern: [HashPattern] { ..., ** }
1080- # 137| getClass: [ConstantReadAccess] Bar
1081- # 137| getScopeExpr: [ConstantReadAccess] Foo
1082- # 137| getKey: [SymbolLiteral] :x
1083- # 137| getValue: [IntegerLiteral] 1
1057+ # 129| getElement: [LocalVariableAccess] x
1058+ # 130| getBranch: [InClause] in ... then ...
1059+ # 130| getPattern: [FindPattern] [ *,...,* ]
1060+ # 130| getPrefixVariableAccess: [LocalVariableAccess] x
1061+ # 130| getElement: [IntegerLiteral] 1
1062+ # 130| getElement: [IntegerLiteral] 2
1063+ # 130| getSuffixVariableAccess: [LocalVariableAccess] y
1064+ # 131| getBranch: [InClause] in ... then ...
1065+ # 131| getPattern: [FindPattern] [ *,...,* ]
1066+ # 131| getClass: [ConstantReadAccess] Bar
1067+ # 131| getScopeExpr: [ConstantReadAccess] Foo
1068+ # 131| getElement: [IntegerLiteral] 1
1069+ # 132| getBranch: [InClause] in ... then ...
1070+ # 132| getPattern: [FindPattern] [ *,...,* ]
1071+ # 132| getClass: [ConstantReadAccess] Foo
1072+ # 132| getElement: [ConstantReadAccess] Bar
1073+ # 137| getStmt: [CaseExpr] case ...
1074+ # 137| getValue: [MethodCall] call to expr
1075+ # 137| getReceiver: [Self, SelfVariableAccess] self
10841076# 138| getBranch: [InClause] in ... then ...
10851077# 138| getPattern: [HashPattern] { ..., ** }
1086- # 138| getClass: [ConstantReadAccess] Bar
1087- # 138| getScopeExpr: [ConstantReadAccess] Foo
1088- # 138| getKey: [SymbolLiteral] :x
1089- # 138| getValue: [IntegerLiteral] 1
1090- # 138| getKey: [SymbolLiteral] :a
1091- # 138| getRestVariableAccess: [LocalVariableAccess] rest
10921078# 139| getBranch: [InClause] in ... then ...
10931079# 139| getPattern: [HashPattern] { ..., ** }
1094- # 139| getClass: [ConstantReadAccess] Foo
1095- # 139| getKey: [SymbolLiteral] :y
1080+ # 139| getKey: [SymbolLiteral] :x
10961081# 140| getBranch: [InClause] in ... then ...
10971082# 140| getPattern: [HashPattern] { ..., ** }
10981083# 140| getClass: [ConstantReadAccess] Bar
1084+ # 140| getScopeExpr: [ConstantReadAccess] Foo
1085+ # 140| getKey: [SymbolLiteral] :x
1086+ # 140| getValue: [IntegerLiteral] 1
10991087# 141| getBranch: [InClause] in ... then ...
11001088# 141| getPattern: [HashPattern] { ..., ** }
11011089# 141| getClass: [ConstantReadAccess] Bar
1102- # 141| getKey: [SymbolLiteral] :a
1090+ # 141| getScopeExpr: [ConstantReadAccess] Foo
1091+ # 141| getKey: [SymbolLiteral] :x
11031092# 141| getValue: [IntegerLiteral] 1
1093+ # 141| getKey: [SymbolLiteral] :a
1094+ # 141| getRestVariableAccess: [LocalVariableAccess] rest
1095+ # 142| getBranch: [InClause] in ... then ...
1096+ # 142| getPattern: [HashPattern] { ..., ** }
1097+ # 142| getClass: [ConstantReadAccess] Foo
1098+ # 142| getKey: [SymbolLiteral] :y
1099+ # 143| getBranch: [InClause] in ... then ...
1100+ # 143| getPattern: [HashPattern] { ..., ** }
1101+ # 143| getClass: [ConstantReadAccess] Bar
1102+ # 144| getBranch: [InClause] in ... then ...
1103+ # 144| getPattern: [HashPattern] { ..., ** }
1104+ # 144| getClass: [ConstantReadAccess] Bar
1105+ # 144| getKey: [SymbolLiteral] :a
1106+ # 144| getValue: [IntegerLiteral] 1
11041107modules/classes.rb:
11051108# 2| [Toplevel] classes.rb
11061109# 3| getStmt: [ClassDeclaration] Foo
0 commit comments