NiceSlice.pm (PDL-2.076) | : | NiceSlice.pm (PDL-2.077) | ||
---|---|---|---|---|
skipping to change at line 51 | skipping to change at line 51 | |||
# | # | |||
# | # | |||
# Modified 2-Oct-2001: don't modify $var(LIST) if it's part of a | # Modified 2-Oct-2001: don't modify $var(LIST) if it's part of a | |||
# "for $var(LIST)" or "foreach $var(LIST)" statement. CED. | # "for $var(LIST)" or "foreach $var(LIST)" statement. CED. | |||
# | # | |||
# Modified 5-Nov-2007: stop processing if we encounter m/^no\s+PDL\;:\;:NiceSlic e\;\s*$/. | # Modified 5-Nov-2007: stop processing if we encounter m/^no\s+PDL\;:\;:NiceSlic e\;\s*$/. | |||
# the next one is largely stolen from Regexp::Common | # the next one is largely stolen from Regexp::Common | |||
my $RE_cmt = qr'(?:(?:\#)(?:[^\n]*)(?:\n))'; | my $RE_cmt = qr'(?:(?:\#)(?:[^\n]*)(?:\n))'; | |||
require PDL; # get PDL version number | ||||
use Text::Balanced; # used to find parenthesis-delimited blocks | use Text::Balanced; # used to find parenthesis-delimited blocks | |||
BEGIN { | BEGIN { | |||
# this is purely for performance reasons - patch: https://github.com/steve-m-hay /Text-Balanced/pull/5 | # this is purely for performance reasons - patch: https://github.com/steve-m-hay /Text-Balanced/pull/5 | |||
my %ref_not_regex = map +($_=>1), qw(CODE Text::Balanced::Extractor); | my %ref_not_regex = map +($_=>1), qw(CODE Text::Balanced::Extractor); | |||
sub my_extract_multiple (;$$$$) # ($text, $functions_ref, $max_fields, $i gnoreunknown) | sub my_extract_multiple (;$$$$) # ($text, $functions_ref, $max_fields, $i gnoreunknown) | |||
{ | { | |||
my $textref = defined($_[0]) ? \$_[0] : \$_; | my $textref = defined($_[0]) ? \$_[0] : \$_; | |||
my $posbug = pos; | my $posbug = pos; | |||
my ($lastpos, $firstpos); | my ($lastpos, $firstpos); | |||
End of changes. 1 change blocks. | ||||
2 lines changed or deleted | 0 lines changed or added |