Why did Matz choose to make Strings mutable by default in Ruby?

Posted by Seth Tisue on Stack Overflow See other posts from Stack Overflow or by Seth Tisue
Published on 2010-04-09T15:01:02Z Indexed on 2010/04/09 15:13 UTC
Read the original article Hit count: 367

It's the reverse of this question: http://stackoverflow.com/questions/93091/why-cant-strings-be-mutable-in-java-and-net

Was this choice made in Ruby only because operations (appends and such) are efficient on mutable strings, or was there some other reason?

(If it's only efficiency, that would seem peculiar, since the design of Ruby seems otherwise to not put a high premium on faciliating efficient implementation.)

© Stack Overflow or respective owner

Related posts about ruby

Related posts about strings