|
From: | Rick Flower |
Subject: | [Help-smalltalk] What is supposed to happen when upToAll: hits the end of stream? |
Date: | Thu, 20 May 2010 16:28:35 -0700 |
User-agent: | RoundCube Webmail/0.2.1 |
I've got some code looking for a line of "----------------" but at the very end of the stream it may instead find a line of "=========". In this case I see this error in version 3.2: error: Invalid argument nil: must be a Character SystemExceptions.WrongClass(Exception)>>signal (ExcHandling.st:254) SystemExceptions.WrongClass class>>signalOn:mustBe: (SysExcept.st:805) SystemExceptions.WrongClass class>>signalOn:mustBe: (SysExcept.st:801) String(Object)>>checkIndexableBounds:put: (Object.st:825) String>>at:put: (String.st:329) WriteStream>>nextPut: (WriteStream.st:93) FileStream(Stream)>>upToAll: (Stream.st:264) The line I was executing was this: (pipe upToAll: '----------------------------') The content of the pipe when this was issued was this (sans the quotes) : "Initial revision =============================================================================" <end of pipe> Any ideas on whether this was proper handling or not? I was hoping it would return the entire string which is what I think it should be doing based on reading the docs.. Comments?
[Prev in Thread] | Current Thread | [Next in Thread] |