From: jtprince Date: 2011-02-26T03:51:42+09:00 Subject: how to override the new/initialize method for a struct? How do I make a custom initializer for a struct object? This is how I would expect it to be accomplished (but this does not work): Dog = Struct.new(:bark, :bite) do def initialize(*args) super(*args) bark = "really loud" unless bark end end dd = Dog.new p dd.bark # => should be "really loud" but is nil So, structs have no initialize method... I tried some other approaches but no luck yet. Can anyone figure out how to do this?