view release on metacpan or search on metacpan
lib/Date/Calendar/Year.pm view on Meta::CPAN
{
LABEL:
foreach $label (keys %{$self->{'TAGS'}{$index}})
{
$upper = ISO_UC($label);
if (index($upper,$pattern) >= $[)
{
push( @result, $index );
last LABEL;
}
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Date/Pcalendar/Year.pm view on Meta::CPAN
{
LABEL:
foreach $label (keys %{$self->{'TAGS'}{$index}})
{
$upper = ISO_UC($label);
if (index($upper,$pattern) >= $[)
{
push( @result, $index );
last LABEL;
}
}
view all matches for this distribution
view release on metacpan or search on metacpan
- Fixed parser to handle new DateTime sanity checks. (We were
returning 7:60 rather then 8:00, which used to work but doesn't
anymore!)
1.0200 Wed 2016-01-27
- Prevent warnings about assignments to $[
- POD fix
- convert to utf-8
- fix some spelling mistakes, following Abgail's Acme::Time::Baby 2010090301.
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Debug/Statements.pm view on Meta::CPAN
my $newsigil = $sigil;
my $reference;
# Ugly way to handle these: $hash{$key} and $hash{$key}{$key2}
# Will not work for more complicated cases like $hash{$hash2{$key}}
while ( $var =~ /^(\$.*)(\$[a-zA-Z_]\w*)(.*)$/ ) {
my ( $pre, $internalvar, $post ) = ( $1, $2, $3 );
if ($id) { print "internaldebug dumpvar: \$internalvar = $internalvar\n" }
my $e = "\$h->{'$internalvar'}";
if ($id) { print "internaldebug dumpvar: \$e = $e\n" }
my $reference = evlwrapper( $h, $e, 'dumpvar $hash{$key}' );
lib/Debug/Statements.pm view on Meta::CPAN
if ($id) { print "internaldebug dumpvar: \$e = $e\n" }
$reference = evlwrapper( $h, $e, 'dumpvar $e' );
} else {
# $_ @_ $1 $&
if ( $var =~ /^(\$_|\@_|\$[1-9]\d*|\$\&)$/ ) {
( my $var2 = $var ) =~ s/^([\$\@\%])//;
#my $sigil = $1;
print "DEBUG sub $caller: WARNING: Debug::Statements::d() does not support Special variables such as $var\n";
print "DEBUG sub $caller: Use double-quotes as a workaround: d(\"$var2 = $var\")\n";
return;
view all matches for this distribution
view release on metacpan or search on metacpan
print cop_file(); # same as __FILE__
print cop_filegv(); # same as \$::{'_<' . __FILE__}
print cop_stashpv(); # same as __PACKAGE__
print cop_stash(); # same as \%{__PACKAGE__ . '::'}
print cop_seq(); # an integer
print cop_arybase(); # same as $[
print cop_line(); # same as __LINE__
# cop_warnings() is only available to Perl 5.8 or below
use warnings;
print cop_warnings(); # same as compile-time ${^WARNING_BITS}
view all matches for this distribution
view release on metacpan or search on metacpan
(thanks to Goro Fuji for providing a patch to
implement all of these, fixes CPAN #47174)
3.19_01 - 2010-02-20
* fix CPAN #50763: mistaken use of $[
(thanks to Zefram for spotting this)
* remove spurious PUSHMARK from Perl_ppaddr_t
(thanks to Gerard Goossen for providing a patch)
* improved support for newer compilers in buildperl.pl
(thanks to Philippe Bruhat (BooK) for providing a patch)
view all matches for this distribution
view release on metacpan or search on metacpan
Refactor.pm view on Meta::CPAN
foreach my $var ( keys %{ $self->{scalar_vars} } ) {
$reg = "\\s*my\\s*\\$var\\s*[=;\(]";
$reg2 = "\\s*my\\s*\\(.*?\\$var.*?\\)";
$reg3 = "(?:for|foreach)\\s+my\\s*\\$var\\s*\\(";
if ( $var =~ /(?:\$\d+$|\$[ab]$)/ ) {
$self->{local_scalars}->{$var}++;
} elsif ( $self->{code_snippet} =~ /$reg|$reg2/ ) {
$self->{local_scalars}->{$var}++;
# skip loop variables
if ( $self->{code_snippet} =~ /$reg3/ ) {
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Devel/Trepan/Util.pm view on Meta::CPAN
# } elsif ($text =~ /^\s*case\s+/) {
# # EXPRESSION in: case EXPESSION
# $text =~ s/^\s*case\s*//;
# } elsif ($text =~ /^\s*sub\s*.*\(.+\)/) {
# $text =~ s/^\s*sub\s*.*\((.*)\)/\(\1\)/;
} elsif ($text =~ /^\s*\$[A-Za-z_][A-Za-z0-9_\[\]]*\s*=[^=>]/) {
# RHS of an assignment statement.
$text =~ s/^\s*[A-Za-z_][A-Za-z0-9_\[\]]*\s*=//;
}
return $text;
}
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Devel/hdb/App/Eval.pm view on Meta::CPAN
my %perl_special_vars = map { $_ => 1 }
qw( $0 $1 $2 $3 $4 $5 $6 $7 $8 $9 $& ${^MATCH} $` ${^PREMATCH} $'
${^POSTMATCH} $+ $^N @+ %+ $. $/ $| $\ $" $; $% $= $- @-
%- $~ $^ $: $^L $^A $? ${^CHILD_ERROR_NATIVE} ${^ENCODING}
$! %! $^E $@ $$ $< $> $[ $] $^C $^D ${^RE_DEBUG_FLAGS}
${^RE_TRIE_MAXBUF} $^F $^H %^H $^I $^M $^O ${^OPEN} $^P $^R
$^S $^T ${^TAINT} ${^UNICODE} ${^UTF8CACHE} ${^UTF8LOCALE}
$^V $^W ${^WARNING_BITS} ${^WIN32_SLOPPY_STAT} $^X @ARGV $ARGV
@F @ARG ); # @_ );
$perl_special_vars{q{$,}} = 1;
view all matches for this distribution
view release on metacpan or search on metacpan
' >$as_me.lineno &&
chmod +x "$as_me.lineno" ||
{ echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
{ (exit 1); exit 1; }; }
# Don't try to exec as it changes $[0], causing all sort of problems
# (the dirname of $[0] is not the place where we might find the
# original and so on. Autoconf is especially sensitive to this).
. "./$as_me.lineno"
# Exit status is that of the last command.
exit
}
' >$as_me.lineno &&
chmod +x "$as_me.lineno" ||
{ echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
{ (exit 1); exit 1; }; }
# Don't try to exec as it changes $[0], causing all sort of problems
# (the dirname of $[0] is not the place where we might find the
# original and so on. Autoconf is especially sensitive to this).
. "./$as_me.lineno"
# Exit status is that of the last command.
exit
}
as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
exec 6>&1
# Save the log message, to keep $[0] and so on meaningful, and to
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by Device::SerialPort $as_me 1.04, which was
generated by GNU Autoconf 2.61. Invocation command line was
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Dios/Types.pm view on Meta::CPAN
# Deparse the constraint sub (if necessary and possible)...
if (!length($constraint_desc//q{}) && eval{ require B::Deparse }) {
state $deparser = B::Deparse->new;
my ($hint_bits, $warning_bits) = (caller 0)[8,9];
$deparser->ambient_pragmas(
hint_bits => $hint_bits, warning_bits => $warning_bits, # '$[' => 0 + $[
);
$constraint_desc = $deparser->coderef2text($constraint);
$constraint_desc =~ s{\s*+ BEGIN \s*+ \{ (?&CODE) \}
(?(DEFINE) (?<CODE> [^{}]*+ (\{ (?&CODE) \} [^{}]*+ )*+ ))}{}gxms;
$constraint_desc =~ s{(?: (?:use|no) \s*+ (?: feature | warnings | strict ) | die \s*+ sprintf ) [^;]* ;}{}gxms;
view all matches for this distribution
view release on metacpan or search on metacpan
lib/Dist/Man/Simple.pm view on Meta::CPAN
my $module_boilerplate_tests;
$module_boilerplate_tests .=
" module_boilerplate_ok('".$self->_module_to_pm_file($_)."');\n" for @modules;
my $boilerplate_tests = @modules + 2 + $[;
$t_files{'boilerplate.t'} = <<"HERE";
#!perl -T
use strict;
use warnings;
view all matches for this distribution
view release on metacpan or search on metacpan
data/t/000-load.t view on Meta::CPAN
BEGIN {
ok(eval 'use [% name %]; 1', 'use [% name %]'); ## no critic (ProhibitStringyEval, RequireCheckingReturnValueOfEval)
}
{
no warnings 'once'; ## no critic (ProhibitNoWarnings)
note("Testing [% name %] $[% name %]::VERSION, Perl $], $^X");
}
done_testing;
view all matches for this distribution