PPSequenceParser.st
changeset 502 1e45d3c96ec5
parent 421 7e08b31e0dae
--- a/PPSequenceParser.st	Thu May 21 14:12:22 2015 +0100
+++ b/PPSequenceParser.st	Fri Jul 24 15:06:54 2015 +0100
@@ -1,5 +1,7 @@
 "{ Package: 'stx:goodies/petitparser' }"
 
+"{ NameSpace: Smalltalk }"
+
 PPListParser subclass:#PPSequenceParser
 	instanceVariableNames:''
 	classVariableNames:''
@@ -9,6 +11,13 @@
 
 
 
+!PPSequenceParser methodsFor:'*petitcompiler'!
+
+map: aBlock
+	^ aBlock numArgs = self children size
+		ifTrue: [ self ==> [ :nodes | aBlock valueWithArguments: nodes ] ]
+		ifFalse: [ self error: aBlock numArgs asString , ' arguments expected.' ]
+! !
 
 
 !PPSequenceParser methodsFor:'operations'!
@@ -26,14 +35,6 @@
 	^ self ==> [ :nodes | anArrayOfIntegers collect: [ :index | nodes at: index ] ]
 ! !
 
-!PPSequenceParser methodsFor:'operators-mapping'!
-
-map: aBlock
-	^ aBlock numArgs = self children size
-		ifTrue: [ self ==> [ :nodes | aBlock valueWithArguments: nodes ] ]
-		ifFalse: [ self error: aBlock numArgs asString , ' arguments expected.' ]
-! !
-
 !PPSequenceParser methodsFor:'parsing'!
 
 parseOn: aPPContext