From: Eric Hodel Date: 2005-11-11T18:04:45+09:00 Subject: Re: Interger( a_symbol ) raises no exception On Nov 10, 2005, at 10:52 PM, Stephan K�mper wrote: > irb(main):001:0> Integer :oops > => 23417 > > Why doesn't that rains an exception? > I alwasy thought Symbols were closer to Strings than Integers > (resp. Fixnums), but I might have been wrong. > > What's the reason for this behaviour? > > I now that there's a unique int associated to each Symbol, but I > still think that a String like "42" IS more like an Integer, > than :a_symbol_like_this. Symbols were originally just numbers, so they have #to_int defined for backwards compatibility. -- Eric Hodel - drbrain@segment7.net - http://segment7.net FEC2 57F1 D465 EB15 5D6E 7C11 332A 551C 796C 9F04