class T::Props::Private::ApplyFixedDefault
def initialize(default, accessor_key, setter_proc)
def initialize(default, accessor_key, setter_proc) # FIXME: Ideally we'd check here that the default is actually a valid # value for this field, but existing code relies on the fact that we don't. # # :( # # setter_proc.call(default) @default = T.let(default, BasicObject) super(accessor_key, setter_proc) end
def set_default(instance)
def set_default(instance) instance.instance_variable_set(@accessor_key, default) end