> ... and as Integers are immutable ++ cannot change the underlying object..

That makes sense : and I guess 'x++'=> x+1 would be just confusing..

I mean like this:

a+=1 (which of course IS valid)

a++ - could in theory mean "Take the value pointed at by a currently, 
increment it and re-point 'a' at that new object"...

but then people might abuse it and not realize (as I hadn't really) that 
Integers are immutable...and give the garbage collector a really hard 
time...

Cheers

John









-- 
Posted via http://www.ruby-forum.com/.