From: Stefan Rusterholz Date: 2007-02-18T00:38:00+09:00 Subject: Re: Oppinions on RCR for dup on immutable classes Gregory Brown wrote: > If I wrote that code, I'd assume it was behaving as I intended, and be > sure to have tests to show it, but truthfully, the code you mentioned > is better. > > It's valid to consider that if you are dup'ing objects that shouldn't > be duped 'by accident', then perhaps something has gone wrong in your > program design. My issue is that I can't test that. I can only try and catch the exception. With dup that's not too terrible as it doesn't have side-effects. Still in my oppinion having to run code to see what happens is not a clean behaviour. My regards -- Posted via http://www.ruby-forum.com/.