Re: perl: Split loop at...

2003-03-11 Thread Cameron Simpson
On 11:43 12 Mar 2003, Telford <[EMAIL PROTECTED]> wrote: | > From: Norman Gaywood <[EMAIL PROTECTED]> | > But I could not find any input that gave the split loop error message. | > The error message is mentioned in man perldiag but it just points you | > to the perldoc -f split page. And as you sai

Re: perl: Split loop at...

2003-03-11 Thread Ade Olonoh
Try: @x2 = split(/,|;/, $token); That worked for me properly, while the code you provided displayed the error. I'm also running v5.8.0, but LANG=en_US.UTF-8. --Ade. > > #!/usr/bin/perl > > > > while(<>) > > { > > @x1 = split(/[\t\n ]+/, \$_); > > print \$., " ", scalar @x1, "

Re: perl: Split loop at...

2003-03-11 Thread Telford
> > From: Norman Gaywood <[EMAIL PROTECTED]> > > But I could not find any input that gave the split loop error message. > The error message is mentioned in man perldiag but it just points you > to the perldoc -f split page. And as you said, this says nothing about > this error. > > Could you pro

Re: perl: Split loop at...

2003-03-09 Thread Stephen Carville
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 It could be related to unicode support. Try: use bytes; However, I cannot reproduce the error. On Sunday 09 March 2003 09:12 pm, Telford wrote: > I've tried this on two different RH8.0 machines: > > > #!/usr/bin/perl > > while(<>) > { > @x

Re: perl: Split loop at...

2003-03-09 Thread Norman Gaywood
On Mon, Mar 10, 2003 at 04:12:13PM +1100, Telford wrote: > I've tried this on two different RH8.0 machines: > > > #!/usr/bin/perl > > while(<>) > { > @x1 = split(/[\t\n ]+/, $_); > foreach $token (@x1) > { > @x2 = split(/[,;]/, $token); > } > } > > > Feed

perl: Split loop at...

2003-03-09 Thread Telford
I've tried this on two different RH8.0 machines: #!/usr/bin/perl while(<>) { @x1 = split(/[\t\n ]+/, $_); foreach $token (@x1) { @x2 = split(/[,;]/, $token); } } Feed it almost any input and you get something like: Split loop at ./test line 8, <>