diff options
author | Eric Wong <e@80x24.org> | 2022-06-20 19:27:28 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2022-06-21 10:39:09 +0000 |
commit | 913b8e2f5c3c85eab5d10112c130db44ee2893c3 (patch) | |
tree | c677d2780a1c8b1fbaee10eebd3654c0ad255c50 | |
parent | 5593489d9c3ce22b1942f35c7ebb0e06fcf2bfa8 (diff) | |
download | public-inbox-913b8e2f5c3c85eab5d10112c130db44ee2893c3.tar.gz |
Current implementations of Perl5 don't have optimizations for single-character field separators (unlike another non-Perl5 VM I'm familiar with).
-rw-r--r-- | lib/PublicInbox/SearchIdx.pm | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/PublicInbox/SearchIdx.pm b/lib/PublicInbox/SearchIdx.pm index 85fae4ad..50e26050 100644 --- a/lib/PublicInbox/SearchIdx.pm +++ b/lib/PublicInbox/SearchIdx.pm @@ -236,8 +236,8 @@ sub index_old_diff_fn { # no renames or space support for traditional diffs, # find the number of leading common paths to strip: - my @fa = split('/', $fa); - my @fb = split('/', $fb); + my @fa = split(m'/', $fa); + my @fb = split(m'/', $fb); while (scalar(@fa) && scalar(@fb)) { $fa = join('/', @fa); $fb = join('/', @fb); @@ -278,12 +278,12 @@ sub index_diff ($$$) { $xnq); } elsif (m!^--- ("?[^/]+/.+)!) { my $fn = $1; - $fn = (split('/', git_unquote($fn), 2))[1]; + $fn = (split(m'/', git_unquote($fn), 2))[1]; $seen{$fn}++ or index_diff_inc($self, $fn, 'XDFN', $xnq); $in_diff = 1; } elsif (m!^\+\+\+ ("?[^/]+/.+)!) { my $fn = $1; - $fn = (split('/', git_unquote($fn), 2))[1]; + $fn = (split(m'/', git_unquote($fn), 2))[1]; $seen{$fn}++ or index_diff_inc($self, $fn, 'XDFN', $xnq); $in_diff = 1; } elsif (/^--- (\S+)/) { |