[25710] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 7950 Volume: 10

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Apr 7 06:05:49 2005

Date: Thu, 7 Apr 2005 03:05:15 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Thu, 7 Apr 2005     Volume: 10 Number: 7950

Today's topics:
    Re: $line = <FH> returns incomplete lines robic0@yahoo.com
    Re: $line = <FH> returns incomplete lines robic0@yahoo.com
    Re: $line = <FH> returns incomplete lines Fred
    Re: $line = <FH> returns incomplete lines (Anno Siegel)
    Re: $line = <FH> returns incomplete lines robic@yahoo.com
    Re: $line = <FH> returns incomplete lines robic@yahoo.com
    Re: $line = <FH> returns incomplete lines robic@yahoo.com
    Re: $line = <FH> returns incomplete lines axel@white-eagle.invalid.uk
    Re: $line = <FH> returns incomplete lines robic@yahoo.com
    Re: $line = <FH> returns incomplete lines <1usa@llenroc.ude.invalid>
    Re: $line = <FH> returns incomplete lines robic@yahoo.com
    Re: $line = <FH> returns incomplete lines robic@yahoo.com
    Re: $line = <FH> returns incomplete lines <1usa@llenroc.ude.invalid>
    Re: $line = <FH> returns incomplete lines <bernard.el-haginDODGE_THIS@lido-tech.net>
    Re: $line = <FH> returns incomplete lines robic@yahoo.com
    Re: $line = <FH> returns incomplete lines robic@yahoo.com
    Re: $line = <FH> returns incomplete lines <bernard.el-haginDODGE_THIS@lido-tech.net>
    Re: Basic Regular Expressions question... <tadmc@augustmail.com>
    Re: Bug in timelocal? <bart.lateur@pandora.be>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Wed, 06 Apr 2005 23:38:40 -0700
From: robic0@yahoo.com
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <v6l9511mrjbr1trro97rc5r5rpgpuqta3c@4ax.com>

On Fri, 01 Apr 2005 19:14:44 +0000, Brian McCauley <nobull@mail.com>
wrote:

>
>
>robic0@yahoo.com wrote:
>
>
>> -rfc
>
>OK
>
>>	if ($line =~ /[\n]+/) {
>
>That condition is more simply written
>
>	if ($line =~ /\n/) {
>
thats true, i've been studying regx.
I'll give you:
              if ($line =~ /\n+/ {
in context...



------------------------------

Date: Thu, 07 Apr 2005 00:04:23 -0700
From: robic0@yahoo.com
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <arm951t30ntr84o5bm49utk28964ng1vae@4ax.com>

On Fri, 01 Apr 2005 19:19:35 +0000, Brian McCauley <nobull@mail.com>
wrote:

>
>
>robic0@yahoo.com wrote:
>
>> $line = '';
>> while(1) {
>> while ( ($line .= <MYLOG> ) )
>> {
>> 	if ($line =~ /[\n]+/) {
>> 		print ("GOT THIS: ",$line);
>> 		$line = '';
>> 	}
>> }
>> seek (MYLOG,0, 1);
>> sleep (1);
>> }
>
>That code will hang busy if a partial line is read.
>
The "while( wait_for_level2_io )" condition is the "<>" mode default.
Perl submits a default Level 2 io read request, then waits for the io
device to deliver a complete entry, which could include more than
one "\n" depending on if the callers process was slowed down.
Perl would return on the last EOL char it gets (there could be
several) OR the EOF condition. Thats why /\n+/ is relavent.
Printing a string with several \n I guess you wouldn't be able 
to tell. Might have to run an assembly program that pumps
multiple \n at high priority to tell for sure.

>It is worse than the OP's solution.



------------------------------

Date: Thu, 07 Apr 2005 01:08:34 -0700
From: Fred
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <u1o951latukr8voluohg62ps44nsgntjv4@4ax.com>

On Sat, 02 Apr 2005 02:22:42 -0600, axel@white-eagle.invalid.uk wrote:

>Brian McCauley <nobull@mail.com> wrote:
>> axel@white-eagle.invalid.uk wrote:
>>> The following seems to work. 
>
>>> #!/usr/bin/perl
>>> 
>>> open (MYLOG, "/tmp/mylog") or die "Cannot open file: $!";
>>> $|++;
>>> 
>>> print "GOT THIS: ";
>>> while ( 1 ) {
>>>     while (<MYLOG>) {
>>>         print;
>>>         print ("GOT THIS: ") if /\n/;
>>>     }  
>>>     sleep (1);
>>> }
>>> __END__
> 
>> That is missing the seek() that is needed to reset the EOF flag on MYLOG.
>> If you insert the seek() it will work, sort of, but only because you are 
>> simply printing the output. 
>
>It works without the seek. Each time some characters are picked up
>they are printed. A new 'GOT THIS' message is only printed once a
>new line is seen in the input (actually it should not be printed
>until at least something has actually been received).
>
>> If you wanted to do someting else - like 
>> selectively print lines by pattern match (as per OP) then it wouldn't work.
>
>I find that it does...  a slightly altered version with a couple of
>pattern matching examples...
>
>1) An specific error message is printed once a full line (i.e.
>   terminated by \n) is found to contain 'error'.
>2) A critical message is printed immediately the incoming line is
>   found to contain 'critical' - there is no wait for the end of
>   line (the message is repeated as the line is built up until
>   terminated by \n).
>
>#!/usr/bin/perl
>
>use warnings;
>use strict;
>
>open (MYLOG, "/tmp/mylog") or die "Cannot open file: $!";
>$|++;
>
>my $line;
>my $prefix = "GOT THIS: ";
>print "Listening\n";
>while ( 1 ) {
>    while (<MYLOG>) {
>        print $prefix, $_;
>        $prefix = '';
>        $line .= $_;
>
>        print "\nCritical *************\n" if $line =~ 'critical';
>        print "Error =============\n" if /\n/ && $line =~ 'error';
>
>        if (/\n/) {
>            $prefix = 'GOT THIS: ';
>            $line = '';
>        } else {
>            $prefix = '';
>        }
>    }
>    sleep (1);
>}
>__END__
>
>
>Axel
>

Hey Axel,

I just wan't to mention some things about level 1 and 2 io.
Perl doesen't emulate platform IO (that I know of). 
If you've ever used terminal emulation you have seen level 1 io,
where the characters are streamed real-time and local
processing might try to buffer, but if its not quick enough
characters are dropped. Thats level 1 io. Level 2 io is
a readline request waiting for the EOL character OR the EOF
condition on your filehandle.  Thats what you are doing.
If the writer is doing level 1 io you will be getting EOF 
condition most of the time. If writer is level 2 and does a
putline with no EOL you will get EOF, or if the writer 
puts a string of escaped crlf's you will get them all
in a single readline. If the reader is too fast, the EOF
condition will always be set. If the reader is slowed
and gets an EOF I don't think the read position will
advance without seek(). So I would leave the seek in.

Btw, so whats wrong with  "while ($line.=<MYLOG>)"
is that a Perl error?

gluck



------------------------------

Date: 7 Apr 2005 08:08:12 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <d32ppc$7lh$1@mamenchi.zrz.TU-Berlin.DE>

 <robic0@yahoo.com> wrote in comp.lang.perl.misc:
> On Fri, 01 Apr 2005 19:19:35 +0000, Brian McCauley <nobull@mail.com>
> wrote:
> 
> >
> >
> >robic0@yahoo.com wrote:
> >
> >> $line = '';
> >> while(1) {
> >> while ( ($line .= <MYLOG> ) )
> >> {
> >> 	if ($line =~ /[\n]+/) {
> >> 		print ("GOT THIS: ",$line);
> >> 		$line = '';
> >> 	}
> >> }
> >> seek (MYLOG,0, 1);
> >> sleep (1);
> >> }
> >
> >That code will hang busy if a partial line is read.
> >
> The "while( wait_for_level2_io )" condition is the "<>" mode default.
> Perl submits a default Level 2 io read request, then waits for the io
> device to deliver a complete entry, which could include more than
> one "\n" depending on if the callers process was slowed down.

Speed has nothing to do with it.

> Perl would return on the last EOL char it gets (there could be
> several) OR the EOF condition. Thats why /\n+/ is relavent.
> Printing a string with several \n I guess you wouldn't be able 
> to tell.

You don't know what you are talking about.  As long as $/ is unchanged,
<MYLOG> will never deliver more than one linefeed.

>          Might have to run an assembly program that pumps
> multiple \n at high priority to tell for sure.

Meaningless buzzwords.

Anno


------------------------------

Date: Thu, 07 Apr 2005 01:13:30 -0700
From: robic@yahoo.com
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <mqq9515ujqt2rl72b5f2t0l8np0u28vamc@4ax.com>

On 26 Mar 2005 01:10:48 GMT, "A. Sinan Unur"
<1usa@llenroc.ude.invalid> wrote:

>"robic0@yahoo.com" <robic0@yahoo.com> wrote in 
>news:1111792017.881420.49180@l41g2000cwc.googlegroups.com:
>
>> Tad McClellan wrote:
>>> robic0@yahoo.com <robic0@yahoo.com> wrote:
>>>
>>> >      if ($line =~ /[\n]+/) {
>>>                       ^  ^
>>>                       ^  ^
>>>
>>> Those 2 characters can serve no useful purpose, so why are they
>>> there?
>>>
>>> Do you understand the code you write?
>>>
>>> --
>
>[ Don't quote signatures ]
>
>> Staying on topic, please give an example of what code is not
>> understandable to you.
>
>You misunderstood Tad's point.
>
>You will need to explain what you think the code above does.
>
>Sinan

I think its mis-aligned trash carets... like your brain 



------------------------------

Date: Thu, 07 Apr 2005 01:14:01 -0700
From: robic@yahoo.com
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <q0n95159dvjkcubrf05j6pcfne11pcmvuc@4ax.com>

On Fri, 01 Apr 2005 19:19:35 +0000, Brian McCauley <nobull@mail.com>
wrote:

>
>
>robic0@yahoo.com wrote:
>
>> $line = '';
>> while(1) {
>> while ( ($line .= <MYLOG> ) )
>> {
>> 	if ($line =~ /[\n]+/) {
>> 		print ("GOT THIS: ",$line);
>> 		$line = '';
>> 	}
>> }
>> seek (MYLOG,0, 1);
>> sleep (1);
>> }
>
>That code will hang busy if a partial line is read.
>
>It is worse than the OP's solution.
test


------------------------------

Date: Thu, 07 Apr 2005 01:14:01 -0700
From: robic@yahoo.com
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <fcl951tfl6813r0112pdr2g6ht7qpp01jb@4ax.com>

On Fri, 01 Apr 2005 19:19:35 +0000, Brian McCauley <nobull@mail.com>
wrote:

>
>
>robic0@yahoo.com wrote:
>
>> $line = '';
>> while(1) {
>> while ( ($line .= <MYLOG> ) )
>> {
>> 	if ($line =~ /[\n]+/) {
>> 		print ("GOT THIS: ",$line);
>> 		$line = '';
>> 	}
>> }
>> seek (MYLOG,0, 1);
>> sleep (1);
>> }
>
>That code will hang busy if a partial line is read.

The "while( wait_for_level2_io )" condition is the "<>" mode default.
Perl submits a default Level 2 io read request, then waits for the io
device to deliver a complete entry, which could include more than
one "\n" depending on if the callers process was slowed down.
Perl would return on the last EOL char it gets (there could be
several) OR the EOF condition. Thats why /\n+/ is relavent.
Printing a string with several \n I guess you wouldn't be able 
to tell. Might have to run an assembly program that pumps
multiple \n at high priority to tell for sure.
>
>It is worse than the OP's solution.



------------------------------

Date: Thu, 07 Apr 2005 03:10:35 -0500
From: axel@white-eagle.invalid.uk
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <8e2dnTbhLLVmd8nfRVn-qg@adelphia.com>

robic0@yahoo.com wrote:
> On Fri, 01 Apr 2005 19:19:35 +0000, Brian McCauley <nobull@mail.com>
>>robic0@yahoo.com wrote:

>>> $line = '';
>>> while(1) {
>>> while ( ($line .= <MYLOG> ) )
>>> {
>>>      if ($line =~ /[\n]+/) {
>>>              print ("GOT THIS: ",$line);
>>>              $line = '';
>>>      }
>>> }
>>> seek (MYLOG,0, 1);
>>> sleep (1);
>>> }

>>That code will hang busy if a partial line is read.

> The "while( wait_for_level2_io )" condition is the "<>" mode default.
> Perl submits a default Level 2 io read request, then waits for the io
> device to deliver a complete entry, which could include more than

In your code as soon as an 'incomplete line' (i.e. a line which is not
terminated by \n) is read, the code will loop continuously in the inner
while loop since the condition will evaluate to true until finally
a \n is read and $line reset to ''.

> one "\n" depending on if the callers process was slowed down.
> Perl would return on the last EOL char it gets (there could be
> several) OR the EOF condition. Thats why /\n+/ is relavent.

It will return on the _next_ EOL character (or EOF condition).

> Printing a string with several \n I guess you wouldn't be able 
> to tell. Might have to run an assembly program that pumps
> multiple \n at high priority to tell for sure.
 
If the data creating program prints several \n characters in the same
print operation,  this reading script will then read several lines.

Axel





------------------------------

Date: Thu, 07 Apr 2005 01:35:01 -0700
From: robic@yahoo.com
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <j4r951dbrb8vnq75i3ctve1od52vn0a8qr@4ax.com>

On 7 Apr 2005 08:08:12 GMT, anno4000@lublin.zrz.tu-berlin.de (Anno
Siegel) wrote:

> <robic0@yahoo.com> wrote in comp.lang.perl.misc:
>> On Fri, 01 Apr 2005 19:19:35 +0000, Brian McCauley <nobull@mail.com>
>> wrote:
>> 
>> >
>> >
>> >robic0@yahoo.com wrote:
>> >
>> >> $line = '';
>> >> while(1) {
>> >> while ( ($line .= <MYLOG> ) )
>> >> {
>> >> 	if ($line =~ /[\n]+/) {
>> >> 		print ("GOT THIS: ",$line);
>> >> 		$line = '';
>> >> 	}
>> >> }
>> >> seek (MYLOG,0, 1);
>> >> sleep (1);
>> >> }
>> >
>> >That code will hang busy if a partial line is read.
>> >
>> The "while( wait_for_level2_io )" condition is the "<>" mode default.
>> Perl submits a default Level 2 io read request, then waits for the io
>> device to deliver a complete entry, which could include more than
>> one "\n" depending on if the callers process was slowed down.
>
>Speed has nothing to do with it.
>
>> Perl would return on the last EOL char it gets (there could be
>> several) OR the EOF condition. Thats why /\n+/ is relavent.
>> Printing a string with several \n I guess you wouldn't be able 
>> to tell.
>
>You don't know what you are talking about.  As long as $/ is unchanged,
><MYLOG> will never deliver more than one linefeed.
>
>>          Might have to run an assembly program that pumps
>> multiple \n at high priority to tell for sure.
>
>Meaningless buzzwords.
>
>Anno

YAFPE - Yeah another fuckin perl expert... 
whats the regex look like on that?
return $1 if ($linebuff =~ /(.*)$\n/)



------------------------------

Date: Thu, 07 Apr 2005 08:44:25 GMT
From: "A. Sinan Unur" <1usa@llenroc.ude.invalid>
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <Xns963130392EFB0asu1cornelledu@127.0.0.1>

robic@yahoo.com wrote in news:j4r951dbrb8vnq75i3ctve1od52vn0a8qr@
4ax.com:

Without giving the impression that this is the only incorrect and 
misleading statement you have made, think about:

> whats the regex look like on that?
> return $1 if ($linebuff =~ /(.*)$\n/)

The pattern you are matching against consists of three parts:

(.*) ... any number of characters
$\   ... The output record separator, undefined by default
n    ... The character n

Hence

#! /usr/bin/perl

use strict;
use warnings;

my $s = "xyz\n\n";

if(my $s =~ /(.*)$\n/) {
    print "Captured: $1\n";
} else {
    print "Didn't match\n";
}

__END__

D:\Home> t
Use of uninitialized value in concatenation (.) or string at D:\Home
\t.pl line 7.
Use of uninitialized value in pattern match (m//) at D:\Home\t.pl line 
7.
Didn't match

-- 
A. Sinan Unur <1usa@llenroc.ude.invalid>
(reverse each component and remove .invalid for email address)

comp.lang.perl.misc guidelines on the WWW:
http://mail.augustmail.com/~tadmc/clpmisc/clpmisc_guidelines.html


------------------------------

Date: Thu, 07 Apr 2005 01:52:04 -0700
From: robic@yahoo.com
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <ais951t30b7q6lh7dgv1i64g9e4jes8gnt@4ax.com>

On Thu, 07 Apr 2005 03:10:35 -0500, axel@white-eagle.invalid.uk wrote:

>robic0@yahoo.com wrote:
>> On Fri, 01 Apr 2005 19:19:35 +0000, Brian McCauley <nobull@mail.com>
>>>robic0@yahoo.com wrote:
>
>>>> $line = '';
>>>> while(1) {
>>>> while ( ($line .= <MYLOG> ) )
>>>> {
>>>>      if ($line =~ /[\n]+/) {
>>>>              print ("GOT THIS: ",$line);
>>>>              $line = '';
>>>>      }
>>>> }
>>>> seek (MYLOG,0, 1);
>>>> sleep (1);
>>>> }
>
>>>That code will hang busy if a partial line is read.
>
>> The "while( wait_for_level2_io )" condition is the "<>" mode default.
>> Perl submits a default Level 2 io read request, then waits for the io
>> device to deliver a complete entry, which could include more than
>
>In your code as soon as an 'incomplete line' (i.e. a line which is not
>terminated by \n) is read, the code will loop continuously in the inner
>while loop since the condition will evaluate to true until finally
>a \n is read and $line reset to ''.

I don't think so, I think <MYLOG> will always advance the read pointer
but you may be right in as much as the EOF condition will not be
cleared causing an immediate return due to EOF (a few cycles).
To fix it:
  while ($line.=<MYLOG>) {
           ......
           seek (MYLOG,0,1);
  }
  sleep(1);

So now its not a looping wait, its a stop wait.....

>
>> one "\n" depending on if the callers process was slowed down.
>> Perl would return on the last EOL char it gets (there could be
>> several) OR the EOF condition. Thats why /\n+/ is relavent.
>
>It will return on the _next_ EOL character (or EOF condition).
>
I don't believe this is true at all... This is a complex io
issue Perl has to optimise without wich could cause race 
conditions. To find out do the tests..... level 1 io writer vs
level 2 reader, where writer has high priority. Try it out.

>> Printing a string with several \n I guess you wouldn't be able 
>> to tell. Might have to run an assembly program that pumps
>> multiple \n at high priority to tell for sure.
> 
>If the data creating program prints several \n characters in the same
>print operation,  this reading script will then read several lines.
>
In one print statement...
>Axel
>
>



------------------------------

Date: Thu, 07 Apr 2005 01:55:17 -0700
From: robic@yahoo.com
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <67t951pt06ptr6agvfctudi1fj3v85fgh3@4ax.com>

On Thu, 07 Apr 2005 08:44:25 GMT, "A. Sinan Unur"
<1usa@llenroc.ude.invalid> wrote:

>robic@yahoo.com wrote in news:j4r951dbrb8vnq75i3ctve1od52vn0a8qr@
>4ax.com:
>
>Without giving the impression that this is the only incorrect and 
>misleading statement you have made, think about:
>
>> whats the regex look like on that?
>> return $1 if ($linebuff =~ /(.*)$\n/)
>
I wrote it rhetorically man, I know exactly what I wrote and that it
won't return a \n,  if u've seen Perl source then just 
post what its doing, don't yank my chain, stop showing off your
great fuckin knowledge... what I don't give a rats ass about

>The pattern you are matching against consists of three parts:
>
>(.*) ... any number of characters
>$\   ... The output record separator, undefined by default
>n    ... The character n
>
>Hence
>
>#! /usr/bin/perl
>
>use strict;
>use warnings;
>
>my $s = "xyz\n\n";
>
>if(my $s =~ /(.*)$\n/) {
>    print "Captured: $1\n";
>} else {
>    print "Didn't match\n";
>}
>
>__END__
>
>D:\Home> t
>Use of uninitialized value in concatenation (.) or string at D:\Home
>\t.pl line 7.
>Use of uninitialized value in pattern match (m//) at D:\Home\t.pl line 
>7.
>Didn't match



------------------------------

Date: Thu, 07 Apr 2005 08:59:25 GMT
From: "A. Sinan Unur" <1usa@llenroc.ude.invalid>
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <Xns963132C3DCABEasu1cornelledu@127.0.0.1>

robic@yahoo.com wrote in news:67t951pt06ptr6agvfctudi1fj3v85fgh3@
4ax.com:

> On Thu, 07 Apr 2005 08:44:25 GMT, "A. Sinan Unur"
> <1usa@llenroc.ude.invalid> wrote:
> 
>>robic@yahoo.com wrote in news:j4r951dbrb8vnq75i3ctve1od52vn0a8qr@
>>4ax.com:
>>
>>Without giving the impression that this is the only incorrect and 
>>misleading statement you have made, think about:
>>
>>> whats the regex look like on that?
>>> return $1 if ($linebuff =~ /(.*)$\n/)
>>
> I wrote it rhetorically man, 

Rhetoric, schmotoric, who cares, it was wrong, and needed to be 
corrected.

> stop showing off your ... knowledge

Not showing off anything, and my knowledge is not that great. If I had 
made that kind of error, I sure would have appreciated it if someone had 
pointed it out. But that's not even relevant. I did not point it out for 
your benefit, but for the benefit of others reading this thread.

You, and your split personality 'Fred', are fairly irrelevant at this 
point.

Sinan

-- 
A. Sinan Unur <1usa@llenroc.ude.invalid>
(reverse each component and remove .invalid for email address)

comp.lang.perl.misc guidelines on the WWW:
http://mail.augustmail.com/~tadmc/clpmisc/clpmisc_guidelines.html


------------------------------

Date: Thu, 7 Apr 2005 11:01:44 +0200
From: "Bernard El-Hagin" <bernard.el-haginDODGE_THIS@lido-tech.net>
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <Xns96317031B23BAelhber1lidotechnet@62.89.127.66>

robic@yahoo.com wrote:

> On 7 Apr 2005 08:08:12 GMT, anno4000@lublin.zrz.tu-berlin.de (Anno
> Siegel) wrote:

[snipped Anno's comments]
 
> YAFPE - Yeah another fuckin perl expert... 


You put it crudely and sarcastically, yet the gist is quite correct. An 
expert he is, one of the more knowledgeable and respected here, and 
this is something, I am confident to say, will be *never* true of you.


> whats the regex look like on that?
> return $1 if ($linebuff =~ /(.*)$\n/)


It is difficult to assess whether it's your manner or your ignorance 
that is more disturbing.


-- 
Cheers,
Bernard


------------------------------

Date: Thu, 07 Apr 2005 02:17:20 -0700
From: robic@yahoo.com
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <h6u9515tbhkkp7a2e22a73vdg11gf4a9uv@4ax.com>

On Thu, 07 Apr 2005 08:59:25 GMT, "A. Sinan Unur"
<1usa@llenroc.ude.invalid> wrote:

>robic@yahoo.com wrote in news:67t951pt06ptr6agvfctudi1fj3v85fgh3@
>4ax.com:
>
>> On Thu, 07 Apr 2005 08:44:25 GMT, "A. Sinan Unur"
>> <1usa@llenroc.ude.invalid> wrote:
>> 
>>>robic@yahoo.com wrote in news:j4r951dbrb8vnq75i3ctve1od52vn0a8qr@
>>>4ax.com:
>>>
>>>Without giving the impression that this is the only incorrect and 
>>>misleading statement you have made, think about:
>>>
>>>> whats the regex look like on that?
>>>> return $1 if ($linebuff =~ /(.*)$\n/)
>>>
>> I wrote it rhetorically man, 
>
>Rhetoric, schmotoric, who cares, it was wrong, and needed to be 
>corrected.
>
>> stop showing off your ... knowledge
>
>Not showing off anything, and my knowledge is not that great. If I had 
>made that kind of error, I sure would have appreciated it if someone had 
>pointed it out. But that's not even relevant. I did not point it out for 
>your benefit, but for the benefit of others reading this thread.
>
>You, and your split personality 'Fred', are fairly irrelevant at this 
>point.
>
>Sinan

Its like readin the funny papers Sinan, if its irrelavent
to you....don't watch, cause I'll be posting along time and
I won't be learning from you.
Does that upset you....



------------------------------

Date: Thu, 07 Apr 2005 02:22:46 -0700
From: robic@yahoo.com
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <eou951ll0f50dsi2ce0pkp1quu73e4thos@4ax.com>

On Thu, 7 Apr 2005 11:01:44 +0200, "Bernard El-Hagin"
<bernard.el-haginDODGE_THIS@lido-tech.net> wrote:

>robic@yahoo.com wrote:
>
>> On 7 Apr 2005 08:08:12 GMT, anno4000@lublin.zrz.tu-berlin.de (Anno
>> Siegel) wrote:
>
>[snipped Anno's comments]
> 
>> YAFPE - Yeah another fuckin perl expert... 
>
>
>You put it crudely and sarcastically, yet the gist is quite correct. An 
>expert he is, one of the more knowledgeable and respected here, and 
>this is something, I am confident to say, will be *never* true of you.
>
>
>> whats the regex look like on that?
>> return $1 if ($linebuff =~ /(.*)$\n/)
>
>
>It is difficult to assess whether it's your manner or your ignorance 
>that is more disturbing.

YARPA - Yet Another Rude prick Arriving,
Yes your a rude prick. I gues its easy to arive on the thread in the
middle of a technical discussion to just criticise without 
contributing anything more than lesson on manners and le ignorance.
Have a happy fuckin life asshole !!!



------------------------------

Date: Thu, 7 Apr 2005 11:34:19 +0200
From: "Bernard El-Hagin" <bernard.el-haginDODGE_THIS@lido-tech.net>
Subject: Re: $line = <FH> returns incomplete lines
Message-Id: <Xns963175B78D384elhber1lidotechnet@62.89.127.66>

robic@yahoo.com wrote:

> On Thu, 7 Apr 2005 11:01:44 +0200, "Bernard El-Hagin"
> <bernard.el-haginDODGE_THIS@lido-tech.net> wrote:
> 
>>robic@yahoo.com wrote:
>>
>>> On 7 Apr 2005 08:08:12 GMT, anno4000@lublin.zrz.tu-berlin.de
>>> (Anno Siegel) wrote:
>>
>>[snipped Anno's comments]
>> 
>>> YAFPE - Yeah another fuckin perl expert... 
>>
>>
>>You put it crudely and sarcastically, yet the gist is quite
>>correct. An expert he is, one of the more knowledgeable and
>>respected here, and this is something, I am confident to say, will
>>be *never* true of you. 
>>
>>
>>> whats the regex look like on that?
>>> return $1 if ($linebuff =~ /(.*)$\n/)
>>
>>
>>It is difficult to assess whether it's your manner or your
>>ignorance that is more disturbing.
> 
> YARPA - Yet Another Rude prick Arriving,
> Yes your a rude prick.


You mean "you're", right? "Your" is possessive, "you're" means "you 
are". Unless you meant "yes your rude prick", but I don't think it's 
that rude at all. It always says "please" and "thank you" and it 
never purports to understand Perl code. None of these things can be 
said about you.


> I gues its easy to arive on the thread in the middle of a technical
> discussion to just criticise without contributing anything more 
> than lesson on manners and le ignorance.


Well yes, quite easy. I just hit "F" (you know, F for follow-up), 
type stuff and hit F8. Is the process more difficult for you?


> Have a happy fuckin life asshole !!!


It's been quite happy up to now, and it will become substantially 
more pleasant as soon as you land in the "2 digit IQ, socially 
challenged kiddies that will never leave here" section of my 
killfile.


*plonk*


-- 
Cheers,
Bernard


------------------------------

Date: Wed, 6 Apr 2005 18:46:02 -0500
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: Basic Regular Expressions question...
Message-Id: <slrnd58t5q.9mq.tadmc@magna.augustmail.com>

Will <kd3qc@yahoo.com> wrote:

> I have a longer program that finds and recursively replaces text in


There is no recursion in what you are doing.


-- 
    Tad McClellan                          SGML consulting
    tadmc@augustmail.com                   Perl programming
    Fort Worth, Texas


------------------------------

Date: Thu, 07 Apr 2005 07:19:24 GMT
From: Bart Lateur <bart.lateur@pandora.be>
Subject: Re: Bug in timelocal?
Message-Id: <dln951poj9sq2t7nu18mrqrhr32mtf7ep7@4ax.com>

yocoyote wrote:

>I'm writing scripts which make heavy use of the timelocal() fct.
>(Time::Local) to get epochtime from a MM/DD hh:mm:ss text date.  I'm
>using activestate perl 5.8.4 build 810 on my pc.  I've found one date,
>among the 10,000's I've successfully transformed, is offset by 3600
>sec.  The 3600 (=1 hour) struck me as not likely a conincidence.  I'm
>wondering if others have seen this before.

Daylight Savings Time. It must be the difference in start/end dates,
between the DST in 1970, and this year.

Use gmtime()/timegm(), and you won't have that.

-- 
	Bart.


------------------------------

Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>


Administrivia:

#The Perl-Users Digest is a retransmission of the USENET newsgroup
#comp.lang.perl.misc.  For subscription or unsubscription requests, send
#the single line:
#
#	subscribe perl-users
#or:
#	unsubscribe perl-users
#
#to almanac@ruby.oce.orst.edu.  

NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice. 

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

#To request back copies (available for a week or so), send your request
#to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
#where x is the volume number and y is the issue number.

#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V10 Issue 7950
***************************************


home help back first fref pref prev next nref lref last post