"Christopher D . Lewis" wrote:
> 
> On Tuesday, January 7, 2003, at 11:19  AM, Peter Scott wrote:
> 
> > [responding to replacement of sub displayResults with {print __LINE__
> > . " sub displayResults";}]
> > That needs to be __LINE__, not __line__.  The above is an error.
> > You do have -w and use strict in this program, right?
> 
> When I use "__LINE__, "... in a test script[1] I get:
> No comma allowed after filehandle at print_line.pl line 5.
> 
> When I use "__LINE__ . "... in a test script[2] I get:
> __line__ sub displayResults
  ^^^^^^^^
  ^^^^^^^^

> (I had imagined __LINE__ might have been intended to print the line
> number in which Perl thought the line occurred, but then, I am not
> familiar with "__" in Perl ...)
> 
> [huge snippage]
> 
> [1]
> #!/usr/bin/perl -w
> # print_line.pl
> 
> use strict
> print __line__, " sub displayResults\n";
        ^^^^^^^^
        ^^^^^^^^

> [2]
> #!/usr/bin/perl -w
> # print_line.pl
> 
> use strict
> print __line__ . " sub displayResults\n";
        ^^^^^^^^
        ^^^^^^^^

This should be __LINE__  NOT __line__



John
-- 
use Perl;
program
fulfillment

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to