From: Martin DeMello Date: 2008-10-23T08:17:31+09:00 Subject: Re: neatest way to extend Struct On Wed, Oct 22, 2008 at 4:04 PM, Siep Korteling wrote: > Martin DeMello wrote: >> I want a Structlike class that takes a hash constructor, so I can say >> >> class A < MyStruct.new(*keys); end >> >> a = A.new(:key1 => val1, :key2 => val2) >> >> Is there any way to base this off Struct? >> >> martin > It'standard: > > require 'ostruct' No, OpenStruct pulls in other things I don't want (the whole 'open' thing). martin