il Sat, 5 Jun 2004 11:15:37 +0900, "Sean O'Dell" <sean / celsoft.com> ha scritto:: >On Friday 04 June 2004 18:34, nobu.nokada / softhome.net wrote: > >In both cases, does that mean that the object has hash-like functionality, or >just that the object responds to those two methods? Is there some definition >somewhere that says "it's a hash if it has these methods?" I actually have >hash-like objects that DON'T respond to either of those two methods, but it >would be easy enough to add fake ones. I hate adding fake methods just to id >a hash interface, it's a kludge. > > Sean O'Dell why do you need to say 'it is hash like' ? Wo'nt it be easyer to say 'I need this methods, so I'll just check them' ? BTW, probably the simpler solution is : x.methods =={}.methods :)