From: Eric Wong Date: Sat, 11 May 2024 23:29:40 +0000 (+0000) Subject: solver: quiet complex regexp warning for old Perl X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4d4d39bbefc5e018eae6998f260d59b9b7979756;p=thirdparty%2Fpublic-inbox.git solver: quiet complex regexp warning for old Perl I'm not sure when the actual recursion limit was removed, but the warning was removed for Perl 5.37.1. In any case, it's probably not worth doing anything about for older Perls it since it's rarely triggered and it seems nobody cares too much about solver, anyways :< --- diff --git a/lib/PublicInbox/SolverGit.pm b/lib/PublicInbox/SolverGit.pm index 296e7d178..7984af436 100644 --- a/lib/PublicInbox/SolverGit.pm +++ b/lib/PublicInbox/SolverGit.pm @@ -136,6 +136,12 @@ sub extract_diff ($$) { if ($cte =~ /\bquoted-printable\b/i && $part->crlf eq "\n") { $s =~ s/\r\n/\n/sg; } + + # Quiet "Complex regular subexpression recursion limit" warning. + # Not much we can do about it, but it's no longer relevant to + # Perl 5.3x (the warning was removed in 5.37.1, and actual + # recursino sometime before then). + no warnings 'regexp'; $s =~ m!( # $1 start header lines we save for debugging: # everything before ^index is optional, but we don't