From: Ari Brown Date: 2007-05-12T10:59:02+09:00 Subject: Re: to_a This is an email that will respond to all who are interested in my misdemeanor among rubists... On May 11, 2007, at 5:15 PM, Martin DeMello wrote: > So you get the deprecation warning when you call to_a on an object of > a class that doesn't provide it, so that the implentation defaults to > Object#to_a. > > Use [obj] instead: Well that certainly seems to do the trick. This is exactly what I did. >>> a = 1 > => 1 >>> a.to_a > (irb):2: warning: default `to_a' will be obsolete > => [1] It produced an error, but I was unsure of what to make of it. I knew that it would be obsoletified, and I thought there was some enumerator function that most people did. I didn't, and still don't, know how to use enumerators in this, or what they can even be fully used for. Help? Apparently .split(//) puts things into an array. Did you know that?!?! I didn't know that!!! >>> [a] > => [1] That's about five more things I just added to my ruby vocabulary :-D --------------------------------------------| If you're not living on the edge, then you're just wasting space.