Question about list context for String.chars

2005-04-11 Thread gcomnz
Hi all, I'm writing a bunch of examples for perl 6 pleac and it seems rather natural to expect $string.chars to return a list of unicode chars in list context, however I can't find anything to confirm that. (The other alternatives being split and unpack.) # unpack @array = unpack(C*, $string);

Re: Question about list context for String.chars

2005-04-11 Thread Ingo Blechschmidt
Hi, gcomnz wrote: I'm writing a bunch of examples for perl 6 pleac and it seems rather natural to expect $string.chars to return a list of unicode chars in list context, however I can't find anything to confirm that. (The other alternatives being split and unpack.) I like that. If one

Whither use English?

2005-04-11 Thread David Vergin
I'm working on docs/S28draft.pod in the pugs project. And consulting perl5's perlvar.pod, the issue of use English comes up. AFAICT from various sources, little has been said about this NOTE: http://groups-beta.google.com/group/perl.perl6.language/msg/fa241233bcfba024: we've already been

Re: Whither use English?

2005-04-11 Thread Juerd
David Vergin skribis 2005-04-11 9:44 (-0700): What's the word. Will there be something like use English? Yes, and it's the default :) Juerd -- http://convolution.nl/maak_juerd_blij.html http://convolution.nl/make_juerd_happy.html http://convolution.nl/gajigu_juerd_n.html

Re: Whither use English?

2005-04-11 Thread Aaron Sherman
On Mon, 2005-04-11 at 14:31, Juerd wrote: David Vergin skribis 2005-04-11 9:44 (-0700): What's the word. Will there be something like use English? Yes, and it's the default :) Yes, but it will be spelled: use $*LANG ;-) Seriously, is there some reason that we would not provide a

Re: Whither use English?

2005-04-11 Thread Juerd
Aaron Sherman skribis 2005-04-11 14:49 (-0400): Yes, but it will be spelled: use $*LANG ;-) Seriously, is there some reason that we would not provide a Language::Russian and Language::Nihongo? Given Perl 6, it would even be quite valid for those modules to add aliases for all of the

Re: Whither use English?

2005-04-11 Thread Mark Reed
On 2005-04-11 15:00, Juerd [EMAIL PROTECTED] wrote: I'm not even sure I like the *possibility* of using non-ascii letters in identifiers, even. I agree that it would be a nightmare if project A used presu instead of print everywhere, while project B used toon, etc. But non-ASCII

Re: Question about list context for String.chars

2005-04-11 Thread Aaron Sherman
On Mon, 2005-04-11 at 14:12, Ingo Blechschmidt wrote: gcomnz wrote: I'm writing a bunch of examples for perl 6 pleac and it seems rather natural to expect $string.chars to return a list of unicode chars in list context, however I can't find anything to confirm that. (The other

Re: Question about list context for String.chars

2005-04-11 Thread gcomnz
I have to say I'm slightly confused too for some languages, especially for syllabic alphabets. At the same time, I'm pretty clear for CJK, Syllabaries, and alphabets, or at least I hope I'm clear (I guess I'm about to find out), .chars just returns the right unicode level for whatever the string

Re: Whither use English?

2005-04-11 Thread Aaron Sherman
On Mon, 2005-04-11 at 15:00, Juerd wrote: Aaron Sherman skribis 2005-04-11 14:49 (-0400): Yes, but it will be spelled: use $*LANG ;-) Seriously, is there some reason that we would not provide a Language::Russian and Language::Nihongo? Given Perl 6, it would even be quite valid for

Re: Question about list context for String.chars

2005-04-11 Thread Mark Reed
On 2005-04-11 15:40, gcomnz [EMAIL PROTECTED] wrote: .chars would return [EMAIL PROTECTED]@, which can probably be expressed with UTF8? The string is probably represented internally as UTF-8, but that should have no effect on what .chars returns, which should, indeed, be [EMAIL PROTECTED],

Re: Question about list context for String.chars

2005-04-11 Thread Aaron Sherman
On Mon, 2005-04-11 at 15:40, gcomnz wrote: I have to say I'm slightly confused too for some languages, especiallyfor syllabic alphabets. At the same time, I'm pretty clear for CJK,Syllabaries, and alphabets, or at least I hope I'm clear (I guess I'mabout to find out), .chars just returns the

Re: Question about list context for String.chars

2005-04-11 Thread gcomnz
abc.chars would return a b c, which I'm guessing would be bytesize usually. Fair enough. .chars would return [EMAIL PROTECTED]@, which can probably be expressed with UTF8? I think you're confusing UTF8 (which can represent ALL Unicode characters) and the UTF8 subset which

Here documents as positional parameters to a function call

2005-04-11 Thread gcomnz
Hey all, more pleac conversion questions: I can't prove with the docs that a heredoc will continue to work as positional params to a function call, particularly where it's not the first param: die Couldn't send mail unless send_mail qq:to/EOTEXT/, $target here doc here ... EOTEXT

Re: Here documents as positional parameters to a function call

2005-04-11 Thread Luke Palmer
gcomnz writes: Hey all, more pleac conversion questions: I can't prove with the docs that a heredoc will continue to work as positional params to a function call, particularly where it's not the first param: die Couldn't send mail unless send_mail qq:to/EOTEXT/, $target here doc

Re: Question about list context for String.chars

2005-04-11 Thread Rod Adams
gcomnz wrote: Hi all, I'm writing a bunch of examples for perl 6 pleac and it seems rather natural to expect $string.chars to return a list of unicode chars in list context, however I can't find anything to confirm that. (The other alternatives being split and unpack.) # unpack @array =

Re: Question about list context for String.chars

2005-04-11 Thread gcomnz
Rod wrote: However, I do like the idea of treating a string as an array of chars. I remember some discussion a while back about making [] on strings do something useful (but not the same thing as Csubstr), but I forget how it ended, and my brain is too fried to go hunt it down. But overall I

Re: Question about list context for String.chars

2005-04-11 Thread Matt Diephouse
On Apr 12, 2005 12:20 AM, gcomnz [EMAIL PROTECTED] wrote: Rod wrote: However, I do like the idea of treating a string as an array of chars. I remember some discussion a while back about making [] on strings do something useful (but not the same thing as Csubstr), but I forget how it

Re: Question about list context for String.chars

2005-04-11 Thread gcomnz
However, I do like the idea of treating a string as an array of chars. I remember some discussion a while back about making [] on strings do something useful (but not the same thing as Csubstr), but I forget how it ended, and my brain is too fried to go hunt it down. But overall I

Re: Question about list context for String.chars

2005-04-11 Thread Rod Adams
Matt Diephouse wrote: On Apr 12, 2005 12:20 AM, gcomnz [EMAIL PROTECTED] wrote: Rod wrote: However, I do like the idea of treating a string as an array of chars. I remember some discussion a while back about making [] on strings do something useful (but not the same thing as Csubstr), but I