I personally do not have problems with freezing nil. As I do not want anything in my apps to metaprogram around in nil's public interface.
But as there are special precautions NOT to freeze nil via the IceNine::Freezer::NilClass I wounder if we should guard against this case or drop the nil specific freezer for symmetry.
Background:
I noticed that the SimpleDelegator freezes nil when updating dependencies to rspec3 where some unrelated edge case made me print nil.frozen?.
A commit in that PR fixes the specs not to call IceNine.deep_freeze(SimpleDelegator.new(nil)) already.
I'm curios what you think about freezing nil @dkubb.
I personally do not have problems with freezing
nil
. As I do not want anything in my apps to metaprogram around innil
's public interface.But as there are special precautions NOT to freeze
nil
via theIceNine::Freezer::NilClass
I wounder if we should guard against this case or drop thenil
specific freezer for symmetry.Background:
I noticed that the SimpleDelegator freezes nil when updating dependencies to rspec3 where some unrelated edge case made me print
nil.frozen?
.A commit in that PR fixes the specs not to call
IceNine.deep_freeze(SimpleDelegator.new(nil))
already.I'm curios what you think about freezing
nil
@dkubb.