Subject: | Patch to fix minor POD bug |
The patch fixes a minor bug in the SYNOPSIS code in the POD: $s is changed
to $_. Also, the line of code with "..." was deleted to allow the SYNOPSIS
code to be copy-and-pasted directly. I also indented the SYNOPSIS code as
a "Verbatim Paragraph" (perldoc perlpod) so that it renders better.
Subject: | diff-u.txt |
--- ../String-PictureFormat-1.1.orig/lib/String/PictureFormat.pm 2016-01-12 00:29:06.000000000 -0500
+++ lib/String/PictureFormat.pm 2016-01-12 10:05:41.322431000 -0500
@@ -10,48 +10,48 @@
=head1 SYNOPSIS
-use String::PictureFormat;
+ use String::PictureFormat;
-$_ = fmt('@"...-..-...."', 123456789);
-print "-formatted=$_=\n"; #RETURNS "123-45-6789".
+ $_ = fmt('@"...-..-...."', 123456789);
+ print "-formatted=$_=\n"; #RETURNS "123-45-6789".
-$_ = unfmt('@"...-..-...."', '123-45-6789');
-print "-unformatted=$_=\n"; #RETURNS "123456789".
+ $_ = unfmt('@"...-..-...."', '123-45-6789');
+ print "-unformatted=$_=\n"; #RETURNS "123456789".
-$_ = fmt('@$,12.2>', 123456789);
-print "-formatted=$_= \n"; #RETURNS " $123,456,789.00".
+ $_ = fmt('@$,12.2>', 123456789);
+ print "-formatted=$_= \n"; #RETURNS " $123,456,789.00".
-$_ = fmtsiz('@$,12.2>');
-print "-format size=$_= \n"; #RETURNS 18.
+ $_ = fmtsiz('@$,12.2>');
+ print "-format size=$_= \n"; #RETURNS 18.
-$_ = fmt('@$,12.2> CR', -123456789);
-print "-formatted=$_=\n"; #RETURNS " $123,456,789.00 CR".
+ $_ = fmt('@$,12.2> CR', -123456789);
+ print "-formatted=$_=\n"; #RETURNS " $123,456,789.00 CR".
-$_ = fmt('@$,12.2> CR', 123456789);
-print "-formatted=$_=\n"; #RETURNS " $123,456,789.00 ".
+ $_ = fmt('@$,12.2> CR', 123456789);
+ print "-formatted=$_=\n"; #RETURNS " $123,456,789.00 ".
-$_ = fmt('@$,12.2>', -123456789);
-print "-formatted=$_=\n"; #RETURNS " $-123,456,789.00".
+ $_ = fmt('@$,12.2>', -123456789);
+ print "-formatted=$_=\n"; #RETURNS " $-123,456,789.00".
-$_ = fmt('@-$,12.2>', -123456789);
-print "-formatted=$_=\n"; #RETURNS " -$123,456,789.00".
+ $_ = fmt('@-$,12.2>', -123456789);
+ print "-formatted=$_=\n"; #RETURNS " -$123,456,789.00".
-$_ = fmt('@$(,12.2>)', -123456789);
-print "-formatted=$_=\n"; #RETURNS " $(123,456,789.00)".
+ $_ = fmt('@$(,12.2>)', -123456789);
+ print "-formatted=$_=\n"; #RETURNS " $(123,456,789.00)".
-$_ = fmt('=16<', 'Now is the time for all good men to come to the aid of their country');
-print "-s=".join('|',@{$s})."=\n"; #RETURNS "Now is the time |for all good men |to come to the aid|of their country =".
+ $_ = fmt('=16<', 'Now is the time for all good men to come to the aid of their country');
+ print "-s=".join('|',@{$_})."=\n"; #RETURNS "Now is the time |for all good men |to come to the aid|of their country =".
-sub foo {
- (my $data = shift) =~ tr/a-z/A-Z/;
- return $data;
-}
-...
-$_ = fmt('@foo()', 'Now is the time for all');
-print "-formatted=$_=\n"; #RETURNS "NOW IS THE TIME FOR ALL"
+ sub foo {
+ (my $data = shift) =~ tr/a-z/A-Z/;
+ return $data;
+ }
+
+ $_ = fmt('@foo()', 'Now is the time for all');
+ print "-formatted=$_=\n"; #RETURNS "NOW IS THE TIME FOR ALL"
-$_ = fmt('@tr/aeiou/AEIOU/', 'Now is the time for all');
-print "-formatted=$_=\n"; #RETURNS "NOw Is thE tImE fOr All"
+ $_ = fmt('@tr/aeiou/AEIOU/', 'Now is the time for all');
+ print "-formatted=$_=\n"; #RETURNS "NOw Is thE tImE fOr All"
=head1 DESCRIPTION