From: matz@... (Yukihiro Matsumoto) Date: 2002-04-11T15:02:44+09:00 Subject: Re: ruby-dev summary 16501-16750 (immutable?) Hi, In message "Re: ruby-dev summary 16501-16750 (immutable?)" on 02/04/11, "Christoph" writes: |> I'm totally against Python's in-place (argumented) assignment. The |> operator "+=" and such work pretty differently depending on whether an |> operand is mutable or not. I feel it's too dangerous and the source |> of confusion. It's OK to make something mutable, but it should |> certainly not any sort of assignment. | |I imagine that seasoned pythoneers are fairly sensitized about |(im)mutability issues so it might not be so dangerous after all? Maybe. But I doubt their decision was right. |> It's not for OO-purity. It's for consisntency of the number system. | |Is consistency always such a good guideline??? Consistency |considerations brought us the dubious definition of #<=> ,<, etc. |(and some sense much worse #==) methods for Complex numbers. |Immutability makes sense for Fixnum, mostly because they are |immediate values and it is consistent with neutering Numerics dup |and clone (of course we can always write ``x+ 0'' by the way) but |enforcing it even for user defined Numeric classes (that was my |interpretation at least? - hope I am wrong) seems unnecessary |to me. I agree consistency is not always the best guideline. But numbers, especially scalar values like integers and floats are too similar. They are numbers just different in their attributes. In such cases, consistency is more important than in other cases. matz.