Re: marine subroutine



On 30 Aug 2007 at 17:29, Martin Barth wrote:

On Thu, 30 Aug 2007 15:39:14 +0100
Andrew Curry <andrew.curry@xxxxxxxxxxxx> wrote:

That's rubbish,

but you get a warning like:

main::a() called too early to check prototype at -e line 1.

Use Prototypes at the beginning of your file if you want to write the subs at the end.


I don't get that either !!!

#!/bin/perl
### junk.pl ###
use strict;
use warnings;

sayhello();


sub sayhello {

print "hello\n";

}


perl junk.pl
hello




.



Relevant Pages