summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/Getopt/Long.pm18
-rw-r--r--lib/Pod/Text.pm15
-rw-r--r--lib/diagnostics.pm2
-rw-r--r--os2/OS2/REXX/REXX.pm6
4 files changed, 21 insertions, 20 deletions
diff --git a/lib/Getopt/Long.pm b/lib/Getopt/Long.pm
index f2b37e917f..fccdf9bc28 100644
--- a/lib/Getopt/Long.pm
+++ b/lib/Getopt/Long.pm
@@ -14,7 +14,7 @@ require Exporter;
@ISA = qw(Exporter);
@EXPORT = qw(&GetOptions $REQUIRE_ORDER $PERMUTE $RETURN_IN_ORDER);
-$VERSION = sprintf("%d.%02d", '$Revision: 2.6 $ ' =~ /(\d+)\.(\d+)/);
+$VERSION = sprintf("%d.%02d", '$Revision: 2.6001 $ ' =~ /(\d+)\.(\d+)/);
use vars qw($autoabbrev $getopt_compat $ignorecase $bundling $order
$passthrough $error $debug
$REQUIRE_ORDER $PERMUTE $RETURN_IN_ORDER
@@ -530,7 +530,7 @@ sub GetOptions {
# than once in differing environments
$error = 0;
- print STDERR ('GetOptions $Revision: 2.6 $ ',
+ print STDERR ('GetOptions $Revision: 2.6001 $ ',
"[GetOpt::Long $Getopt::Long::VERSION] -- ",
"called from package \"$pkg\".\n",
" (@ARGV)\n",
@@ -566,7 +566,7 @@ sub GetOptions {
my $opt = shift (@optionlist);
# Strip leading prefix so people can specify "--foo=i" if they like.
- $opt = $' if $opt =~ /^($genprefix)+/;
+ $opt = $+ if $opt =~ /^($genprefix)+(.*)/s;
if ( $opt eq '<>' ) {
if ( (defined $userlinkage)
@@ -854,19 +854,19 @@ sub GetOptions {
sub find_option {
- return 0 unless $opt =~ /^$genprefix/;
+ return 0 unless $opt =~ /^($genprefix)(.*)/s;
- $opt = $';
- my ($starter) = $&;
+ $opt = $+;
+ my ($starter) = $1;
my $optarg = undef; # value supplied with --opt=value
my $rest = undef; # remainder from unbundling
# If it is a long option, it may include the value.
if (($starter eq "--" || $getopt_compat)
- && $opt =~ /^([^=]+)=/ ) {
+ && $opt =~ /^([^=]+)=(.*)/s ) {
$opt = $1;
- $optarg = $';
+ $optarg = $2;
print STDERR ("=> option \"", $opt,
"\", optarg = \"$optarg\"\n") if $debug;
}
@@ -992,7 +992,7 @@ sub find_option {
# Get key if this is a "name=value" pair for a hash option.
$key = undef;
if ($hash && defined $arg) {
- ($key, $arg) = ($arg =~ /=/o) ? ($`, $') : ($arg, 1);
+ ($key, $arg) = ($arg =~ /(.*?)=(.*)/s) ? ($1, $2) : ($arg, 1);
}
#### Check if the argument is valid for this option ####
diff --git a/lib/Pod/Text.pm b/lib/Pod/Text.pm
index 9d6636a82f..2ecaebe609 100644
--- a/lib/Pod/Text.pm
+++ b/lib/Pod/Text.pm
@@ -1,7 +1,5 @@
package Pod::Text;
-# Version 1.02
-
=head1 NAME
Pod::Text - convert POD data to formatted ASCII text
@@ -49,6 +47,9 @@ require Exporter;
@ISA = Exporter;
@EXPORT = qw(pod2text);
+use vars qw($VERSION);
+$VERSION = "1.0201";
+
$termcap=0;
#$use_format=1;
@@ -116,18 +117,18 @@ POD_DIRECTIVE: while (<IN>) {
next;
}
- if (/^=for\s+(\S+)\s*/s) {
+ if (/^=for\s+(\S+)\s*(.*)/s) {
if ($1 eq "text") {
- print STDOUT $',"";
+ print STDOUT $2,"";
} else {
# ignore unknown for
}
next;
}
- elsif (/^=begin\s+(\S+)\s*/s) {
+ elsif (/^=begin\s+(\S+)\s*(.*)/s) {
$begun = $1;
if ($1 eq "text") {
- print STDOUT $'."";
+ print STDOUT $2."";
}
next;
}
@@ -409,7 +410,7 @@ sub clear_noremap {
defined $HTML_Escapes{$3}
? do { $HTML_Escapes{$3} }
: do {
- warn "Unknown escape: $& in $_";
+ warn "Unknown escape: E<$1> in $_";
"E<$1>";
}
}
diff --git a/lib/diagnostics.pm b/lib/diagnostics.pm
index bbae58e12b..0aa5b54195 100644
--- a/lib/diagnostics.pm
+++ b/lib/diagnostics.pm
@@ -500,7 +500,7 @@ sub unescape {
exists $HTML_Escapes{$1}
? do { $HTML_Escapes{$1} }
: do {
- warn "Unknown escape: $& in $_";
+ warn "Unknown escape: E<$1> in $_";
"E<$1>";
}
}
diff --git a/os2/OS2/REXX/REXX.pm b/os2/OS2/REXX/REXX.pm
index 78e0cf917d..114e1592c4 100644
--- a/os2/OS2/REXX/REXX.pm
+++ b/os2/OS2/REXX/REXX.pm
@@ -107,21 +107,21 @@ sub dropall
sub TIESCALAR
{
my ($obj, $name) = @_;
- $name =~ s/^[\w!?]+/\U$&\E/;
+ $name =~ s/^([\w!?]+)/\U$1\E/;
return bless \$name, OS2::REXX::_SCALAR;
}
sub TIEARRAY
{
my ($obj, $name) = @_;
- $name =~ s/^[\w!?]+/\U$&\E/;
+ $name =~ s/^([\w!?]+)/\U$1\E/;
return bless [$name, 0], OS2::REXX::_ARRAY;
}
sub TIEHASH
{
my ($obj, $name) = @_;
- $name =~ s/^[\w!?]+/\U$&\E/;
+ $name =~ s/^([\w!?]+)/\U$1\E/;
return bless {Stem => $name}, OS2::REXX::_HASH;
}