X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2Fsubs.pm;h=aa332a678583068d3dd77538fbf9c161ddc638bb;hb=5dce09b1b12bc4dff9713d5dbb5291ac967ccf63;hp=8b5835770fa5c8cf00a93d49e4c5023b0d6abbdc;hpb=a0d0e21ea6ea90a22318550944fe6cb09ae10cda;p=p5sagit%2Fp5-mst-13.2.git diff --git a/lib/subs.pm b/lib/subs.pm index 8b58357..aa332a6 100644 --- a/lib/subs.pm +++ b/lib/subs.pm @@ -1,8 +1,30 @@ package subs; -require 5.000; +=head1 NAME + +subs - Perl pragma to predeclare sub names + +=head1 SYNOPSIS + + use subs qw(frob); + frob 3..10; + +=head1 DESCRIPTION -$ExportLevel = 0; +This will predeclare all the subroutine whose names are +in the list, allowing you to use them without parentheses +even before they're declared. + +Unlike pragmas that affect the C<$^H> hints variable, the C and +C declarations are not BLOCK-scoped. They are thus effective +for the entire file in which they appear. You may not rescind such +declarations with C or C. + +See L and L. + +=cut + +require 5.000; sub import { my $callpack = caller;