diff -r a949c4fe44df -r a8feb0f47574 compiler/tests/PPCCodeGeneratorTest.st --- a/compiler/tests/PPCCodeGeneratorTest.st Sat Aug 29 07:56:14 2015 +0100 +++ b/compiler/tests/PPCCodeGeneratorTest.st Fri Sep 04 14:06:56 2015 +0100 @@ -24,20 +24,20 @@ ! setUp - options := PPCCompilationOptions default - profile: true. + options := PPCCompilationOptions default + tokenize: false; + profile: true; + yourself. - configuration := PPCPluggableConfiguration on: [ :_self | - options cacheFirstFollow ifTrue:[ - _self runPass: PPCCacheFirstFollowPass. - ]. - _self runPass: PPCCheckingVisitor. - _self runPass: PPCUniversalCodeGenerator. - _self generateParser. - ]. + configuration := PPCConfiguration new passes: + { + PPCCacheFirstFollowPass. + PPCCheckingVisitor . + PPCUniversalCodeGenerator . + }. configuration options: options. - "Modified: / 04-09-2015 / 10:31:47 / Jan Vrany " + "Modified: / 04-09-2015 / 16:22:30 / Jan Vrany " ! tearDown @@ -928,7 +928,7 @@ ! testStarAnyNode - options cacheFirstFollow: false. + configuration removePass: PPCCacheFirstFollowPass. node := PPCStarAnyNode new child: PPCNilNode new; yourself. @@ -937,10 +937,12 @@ self assert: parser parse: 'abc' to: #($a $b $c). self assert: parser parse: 'a' to: #($a). self assert: parser parse: '' to: #(). + + "Modified: / 04-09-2015 / 14:47:52 / Jan Vrany " ! testStarCharSetPredicateNode - options cacheFirstFollow: false. + configuration removePass: PPCCacheFirstFollowPass. node := PPCStarCharSetPredicateNode new predicate: (PPCharSetPredicate on: [:e | e = $a ]); child: PPCSentinelNode new; @@ -953,11 +955,12 @@ self assert: context invocationCount = 1. self assert: parser parse: 'bba' to: #() end: 0. self assert: context invocationCount = 1. - + + "Modified: / 04-09-2015 / 14:47:57 / Jan Vrany " ! testStarMessagePredicateNode - options cacheFirstFollow: false. + configuration removePass: PPCCacheFirstFollowPass. node := PPCStarMessagePredicateNode new message: #isLetter; child: PPCSentinelNode new; @@ -971,7 +974,8 @@ self assert: parser parse: '123a' to: #() end: 0. self assert: context invocationCount = 1. - + + "Modified: / 04-09-2015 / 14:48:05 / Jan Vrany " ! testStarNode @@ -1035,8 +1039,8 @@ message: #isLetter; child: PPCSentinelNode new; yourself. - options cacheFirstFollow: false. - options guards: false. + configuration removePass: PPCCacheFirstFollowPass. + options guards: false. self compileTree: node. self assert: parser class methodDictionary size = 1. @@ -1048,6 +1052,8 @@ self assert: context rememberCount = 0. self assert: parser parse: 'foo123' to: parser end: 3. + + "Modified: / 04-09-2015 / 14:48:13 / Jan Vrany " ! testTokenStarSeparatorNode @@ -1060,14 +1066,15 @@ node := PPCForwardNode new child: starNode; yourself. - options cacheFirstFollow: false. + configuration removePass: PPCCacheFirstFollowPass. self compileTree: node. self assert: parser class methodDictionary size = 2. self assert: parser parse: ' a' to: parser end: 3. self assert: context invocationCount = 2. - + + "Modified: / 04-09-2015 / 14:48:20 / Jan Vrany " ! testTokenStarSeparatorNode2 @@ -1080,15 +1087,16 @@ yourself. node := PPCForwardNode new child: starNode; - yourself. - options cacheFirstFollow: false. + yourself. + configuration removePass: PPCCacheFirstFollowPass. self compileTree: node. self assert: parser class methodDictionary size = 1. self assert: parser parse: ' a' to: context end: 3. self assert: context invocationCount = 1. - + + "Modified: / 04-09-2015 / 14:48:29 / Jan Vrany " ! testTrimNode