class S class << self attr_accessor :singleton end attr_accessor :value def initialize @value = "xxx" S.singleton = self def S.new S.singleton end end end a = S.new # => #<S:0x007ff4a41532e0 @value="xxx"> b = S.new #=> #<S:0x007ff4a41532e0 @value="xxx"> a.value = "zzz" b.value # "zzz" a.object_id == b.object_id #=> true