On 27 Apr 00 22:16:29 MDT Scott Durno scottdurno@usa.net wrote:
When I -> Do it the transcript displays several rows of 5 digit numbers and I do not know what they are. This works fine in st express. What does Squeak do different?
Thanks in advance
James,
The difference is that in Squeak #nextWord means a two-byte binary number rather that a string of characters delimited by separator characters. The method below would do what you want.
Cheers, Bob
===== code follows ===== 'From Squeak2.8alpha of 13 January 2000 [latest update: #2042] on 28 April 2000 at 11:29:19 am'!
!PositionableStream methodsFor: 'accessing' stamp: 'RAA 4/28/2000 11:28'! upToNextSeparator
| startPos endMatch result | startPos _ self position. [self atEnd] whileFalse: [ self next isSeparator ifTrue: [ endMatch _ self position. self position: startPos. result _ self next: endMatch - startPos - 1. self position: endMatch. self skipSeparators. ^ result ]. ]. self position: startPos. ^ self upToEnd! !
squeak-dev@lists.squeakfoundation.org