Workaround to fix PPComposedTest>>testLeftRecursion - make PPStream>>size returning size of the input.
For whatever reason, in Smalltalk/X ReadStream>>size returns size remaning data, not
the size of a whole stream. This is a bug and should be fixed in Smalltalk/X libbasic. Meanwhile,
override PPStream>>size to return proper value. In Pharo, the method is not needed as the inherited
method is exactly the same.
"{ Package: 'stx:goodies/petitparser' }"
Object subclass:#PPMemento
instanceVariableNames:'result count context'
classVariableNames:''
poolDictionaries:''
category:'PetitParser-Core'
!
!PPMemento class methodsFor:'instance creation'!
new
^ self basicNew initialize
! !
!PPMemento methodsFor:'accessing'!
contextMemento
^ context
!
contextMemento: aPPContextMemento
context := aPPContextMemento
!
result
^ result
!
result: anObject
result := anObject
! !
!PPMemento methodsFor:'accessing-readonly'!
count
^ count
! !
!PPMemento methodsFor:'actions'!
increment
count := count + 1
! !
!PPMemento methodsFor:'initialization'!
initialize
count := 0
! !
!PPMemento class methodsFor:'documentation'!
version
^ '$Header: /cvs/stx/stx/goodies/petitparser/PPMemento.st,v 1.3 2012-05-04 22:00:45 vrany Exp $'
!
version_CVS
^ '$Header: /cvs/stx/stx/goodies/petitparser/PPMemento.st,v 1.3 2012-05-04 22:00:45 vrany Exp $'
!
version_SVN
^ '§Id: PPMemento.st 2 2010-12-17 18:44:23Z vranyj1 §'
! !