--- a/compiler/tests/PPCNodeFirstFollowNextTests.st Wed Aug 26 23:34:48 2015 +0100
+++ b/compiler/tests/PPCNodeFirstFollowNextTests.st Sat Aug 29 07:56:14 2015 +0100
@@ -25,7 +25,9 @@
setUp
configuration := PPCConfiguration default.
- configuration options generate: false.
+ configuration context options generate: false.
+
+ "Modified: / 28-08-2015 / 14:17:57 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !
!PPCNodeFirstFollowNextTests methodsFor:'support'!
@@ -162,7 +164,7 @@
!
testFirstNegate1
- configuration options specialize: true.
+ configuration context options specialize: true.
tree := self treeFrom: ('a' asParser negate, 'b' asParser).
first := self first: tree.
@@ -170,6 +172,8 @@
self assert: first size: 1.
self assert: first anyMatchesType: PPCNotNode.
self assert: first anyOne child literal = 'a'.
+
+ "Modified: / 28-08-2015 / 14:18:11 / Jan Vrany <jan.vrany@fit.cvut.cz>"
!
testFirstNot
@@ -183,7 +187,7 @@
!
testFirstNot2
- configuration options specialize: true.
+ configuration context options specialize: true.
tree := self treeFrom: (#letter asParser not star, #letter asParser).
first := self first: tree.
@@ -191,6 +195,8 @@
self assert: first size: 2.
self assert: first anyMatchesType: PPCNotNode.
self assert: first anyMatchesType: PPCPredicateNode.
+
+ "Modified: / 28-08-2015 / 14:18:27 / Jan Vrany <jan.vrany@fit.cvut.cz>"
!
testFirstNot4
@@ -323,11 +329,13 @@
!
testFirstSequence6
- configuration options specialize: true.
+ configuration context options specialize: true.
tree := self treeFrom: #space asParser star, 'a' asParser.
tree firstFollowCache: nil.
self should: [ self first: tree. ] raise: Exception.
+
+ "Modified: / 28-08-2015 / 14:18:34 / Jan Vrany <jan.vrany@fit.cvut.cz>"
!
testFirstSequence7
@@ -351,7 +359,7 @@
!
testFirstStarMessagePredicate2
- configuration options specialize: true.
+ configuration context options specialize: true.
tree := self treeFrom: #space asParser star.
first := self first: tree.
@@ -359,18 +367,20 @@
self assert: first size: 2.
self assert: first anyMatchesType: PPCMessagePredicateNode.
self assert: first anyMatchesType: PPCSentinelNode.
-
-
+
+ "Modified: / 28-08-2015 / 14:18:42 / Jan Vrany <jan.vrany@fit.cvut.cz>"
!
testFirstTerminal
- configuration options specialize: true.
+ configuration context options specialize: true.
tree := self treeFrom: 'a' asParser not.
first := self first: tree.
self assert: first size: 1.
self assert: (self first: tree) anyMatchesType: PPCNotLiteralNode.
+
+ "Modified: / 28-08-2015 / 14:18:48 / Jan Vrany <jan.vrany@fit.cvut.cz>"
!
testFirstTerminal2
@@ -659,18 +669,20 @@
testFollowTrimmingToken
| token1 token2 |
- configuration options specialize: false.
+ configuration context options specialize: false.
token1 := #letter asParser plus trimmingToken name: 'token1'; yourself.
token2 := #letter asParser plus trimmingToken name: 'token2'; yourself.
tree := self treeFrom: token1, token2.
- followSet := self followOf: 'token1'
+ followSet := self followOf: 'token1'
in: tree
suchThat: [:e | e isFirstSetTerminal or: [e isKindOf: PPCTrimmingTokenNode ]].
self assert: followSet size: 1.
- self assert: followSet anyMatchesType: PPCTrimmingTokenNode.
+ self assert: followSet anyMatchesType: PPCTrimmingTokenNode.
+
+ "Modified: / 28-08-2015 / 14:18:55 / Jan Vrany <jan.vrany@fit.cvut.cz>"
! !
!PPCNodeFirstFollowNextTests class methodsFor:'documentation'!