islands/PPInputEnds.st
changeset 387 e2b2ccaa4de6
child 389 009c2e13973c
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/islands/PPInputEnds.st	Wed Oct 08 00:33:44 2014 +0100
@@ -0,0 +1,34 @@
+"{ Package: 'stx:goodies/petitparser/islands' }"
+
+PPParser subclass:#PPInputEnds
+	instanceVariableNames:''
+	classVariableNames:''
+	poolDictionaries:''
+	category:'PetitIslands-Parsers'
+!
+
+PPInputEnds comment:''
+!
+
+!PPInputEnds methodsFor:'as yet unclassified'!
+
+acceptsEpsilon
+	^ true
+!
+
+exampleOn: aStream 
+	aStream nextPutAll: '#End Of Input#'
+!
+
+isNullable 
+	^ true
+!
+
+parseOn: aPPContext
+	(aPPContext atEnd) ifFalse:
+	[
+		^ PPFailure message: 'end of input expected' context: aPPContext.
+	].
+	^ #inputEnds
+! !
+