From: Robert Klemme Date: 2012-06-21T07:43:07+09:00 Subject: Re: Symbols and Strings... On Thu, Jun 21, 2012 at 12:25 AM, Hal Fulton wrote: > > On Wed, Jun 20, 2012 at 5:06 PM, Jeremy Bopp wrote: >> >> So then, in what cases would it be helpful to use them interchangeably? >>  Is it possible to define a common, useful interface that both Symbol >> and String could implement.  If so, perhaps a class or module could be >> defined for that interface and incorporated into both classes as >> appropriate. >> >> From what I've seen, the most frequently voiced desire is to be able to >> use apparently equivalent symbols and strings as fully equivalent hash >> keys. Even that would not be solved by inheritance because instance of different classes can never be equivalent. Kind regards robert PS: I said "If at all..." - so I am not a fan of String as subclass of Symbol either. -- remember.guy do |as, often| as.you_can - without end http://blog.rubybestpractices.com/