Issues creating instance of SmallInteger

stéphane ducasse ducasse at
Fri May 12 16:53:05 UTC 2006

Hi Michel

May be Object readFrom: '1'  is what you need. Because certain  
objects can't be created with new.


On 12 mai 06, at 17:32, Michel Calonne wrote:

> Hello,
> I've got a problem creating objects via this sample of code:
> (Smalltalk at: #AClassName) new
> The problem is that, when trying to create an instance of  
> SmallInteger, it raises an error :
> "SmallIntegers can only be created by performing arithmetic"...
> If somebody can tell me why it isn't possible to create a  
> SmallInteger like this, and give me a way to do it, I'd appreciate...
> And are there other classes behaving the same way? So that I can  
> take them in account in my code.
> Thank you for reading this!

More information about the Squeak-dev mailing list