[squeak-dev] Endless recursion: "String new: -1"

David T. Lewis lewis at mail.msen.com
Thu Jul 7 01:26:48 UTC 2016


On Wed, Jul 06, 2016 at 06:43:25AM -0700, marcel.taeumel wrote:
> Hi, there!
> 
> Is it okay that there is an endless recursion when evaluating "String new: -1"?

No, it is not okay. It should fail with a primitive failure.

Dave


> 
> ...
> ByteString class(Behavior)>>handleFailingFailingBasicNew:
> ByteString class(Behavior)>>handleFailingBasicNew:
> ByteString class(Behavior)>>basicNew:
> ByteString class(Behavior)>>handleFailingFailingBasicNew:
> ByteString class(Behavior)>>handleFailingBasicNew:
> ByteString class(Behavior)>>basicNew:
> ByteString class(Behavior)>>handleFailingFailingBasicNew:
> ByteString class(Behavior)>>handleFailingBasicNew:
> ByteString class(Behavior)>>basicNew:
> ...
> 
> I would like to have an error signaled instead. Note that the -1 is just an
> example for a bad computation. The error I get is "Space is low" then. :-)
> 
> 
> Best,
> Marcel
> 
> 
> 
> --
> View this message in context: http://forum.world.st/Endless-recursion-String-new-1-tp4905179.html
> Sent from the Squeak - Dev mailing list archive at Nabble.com.


More information about the Squeak-dev mailing list