and add a warnings.t test case to check for that warning
++$x;
use warnings "numeric";
$x = "a_c"; ++$x;
+$x = ${ qr/abc/ }; ++$x;
$x = 0; ++$x; # none of these should warn
$x = "ABC"; ++$x;
$x = "ABC123"; ++$x;
$x = " +10"; ++$x;
EXPECT
Argument "a_c" treated as 0 in increment (++) at - line 5.
+Argument "(?^:abc)" treated as 0 in increment (++) at - line 6.
$_ = ${qr //};
$_--;
is($_, -1, 'regexp--');
-$_ = ${qr //};
-$_++;
-is($_, 1, 'regexp++');
+{
+ no warnings 'numeric';
+ $_ = ${qr //};
+ $_++;
+ is($_, 1, 'regexp++');
+}
$_ = v97;
$_++;