@freemo Ruby's handling of immutability hasn't really changed, besides adding frozen_string_literal. There are several libraries that do recursive-freezing of objects or define immutable Struct-like objects. I've found that being mindful of API boundaries and object ownership prevents a lot of the mutability horror stories.
@postmodern Oh I agree, the handling of immutability has been less than elegant since the get go.. but its not really a ruby problem.. no OO language handles it all that well to be honest.
CleverLibre Social is an inclusive social instance for open discussion, learning, and community.
All cultures welcome.
Hate speech and harassment strictly forbidden.
@freemo Ruby's handling of immutability hasn't really changed, besides adding frozen_string_literal. There are several libraries that do recursive-freezing of objects or define immutable Struct-like objects. I've found that being mindful of API boundaries and object ownership prevents a lot of the mutability horror stories.