Re: is it bug? for
- From: "Gregory Brown" <gregory.t.brown@xxxxxxxxx>
- Date: Sat, 30 Jun 2007 23:15:08 +0900
On 6/30/07, Axel Etzold <AEtzold@xxxxxx> wrote:
> Well, yours isn't correct. On 1.8:
>
> >> "a\nb\nc\n".to_a
> => ["a\n", "b\n", "c\n"]
>
> The code you mentioned is just:
>
> ["a\nb\nc\n"]
Ok, but do you know that that's what the OP wanted ?
Best regards,
I can only assume so seeing as this is the behaviour of String#to_a in
1.8 and it does not exist in 1.9
But no, he'd need to answer that. Typically if you want to do that
kind of manipulation, Array() is better, anyhow.
=> [1, 2, 3]Array([1,2,3])
=> ["foo"]Array("foo")
.
- Follow-Ups:
- Re: is it bug? for
- From: Axel Etzold
- Re: is it bug? for
- References:
- is it bug? for
- From: Chung Chung
- Re: is it bug? for
- From: Axel Etzold
- Re: is it bug? for
- From: Bertram Scharpf
- Re: is it bug? for
- From: Axel Etzold
- Re: is it bug? for
- From: Gregory Brown
- Re: is it bug? for
- From: Axel Etzold
- is it bug? for
- Prev by Date: Re: is it bug? for
- Next by Date: Re: is it bug? for
- Previous by thread: Re: is it bug? for
- Next by thread: Re: is it bug? for
- Index(es):
Relevant Pages
|