If C<$/> is a reference to an integer, or a scalar that holds an integer,
<> will read in records instead of lines. For more info, see
-L<perlvar/$/>.
+L<perlvar/$E<sol>>.
=head1 Supported Platforms
argument localtime uses the current time.
$day_of_year = (localtime)[7];
-
+
The POSIX module can also format a date as the day of the year or
week of the year.
To get the day of year for any date, use the Time::Local module to get
a time in epoch seconds for the argument to localtime.
-
+
use POSIX qw/strftime/;
use Time::Local;
my $week_of_year = strftime "%W",
use Date::Calc;
my $day_of_year = Day_of_Year( 1987, 12, 18 );
my $week_of_year = Week_of_Year( 1987, 12, 18 );
-
+
=head2 How do I find the current century or millennium?
Use the following simple functions:
print Perl_sv_2pv_nolen(sv)
+=back
+
You may find it helpful to have a "macro dictionary", which you can
produce by saying C<cpp -dM perl.c | sort>. Even then, F<cpp> won't
recursively apply those macros for you.
means configuring with C<-Doptimize=-g3>. Other compilers might use a
different switch (if they support debugging macros at all).
-=back
-
=head2 Dumping Perl Data Structures
One way to get around this macro hell is to use the dumping functions in
sleep 2; # to avoid dup signals
}
-=head2 Deferred Signals (Safe signals)
+=head2 Deferred Signals (Safe Signals)
In Perls before Perl 5.7.3 by installing Perl code to deal with
signals, you were exposing yourself to danger from two things. First,
(Note that the template C<A*> would only have packed C<$str[0]> in full
length.)
-
+
To pack dates stored as triplets ( day, month, year ) in an array C<@dates>
into a sequence of byte, byte, short integer we can write