On Tue, Dec 12, 2017 at 06:23:47AM +0000, Yaroslav Kuzmin wrote:
> Log available at
> https://drive.google.com/file/d/1jGDVWAw-L_ZBZHzfupDKy5uBNRKI9Dm7<https://drive.google.com/file/d/1jGDVWAw-L_ZBZHzfupDKy5uBNRKI9Dm7/view?usp=sharing>
Strange. In that run, it is failing four tests. In each case, a string
concatentation is inserting a spurious null character. For example with
$function = "XDIGIT";
$suffix = "_utf8"; # or "_LC_utf8"
$char = "\x{b3}"; utf8::upgrade($char);
$utf8_param_code = "0"; # or "-1"
"test_is${function}$suffix('$char',";
the result is
"test_isXDIGIT\x{0}_utf8('\x{b3}', 0)"
with similar results for the variants shown in the comments.
If you do further runs, do you get the same 4 tests consistently failing?
Can you run the attached test script and show any output. If should produce
no output normally.
--
My Dad used to say 'always fight fire with fire', which is probably why
he got thrown out of the fire brigade.
use Devel::Peek;
sub set_code { $_[0] = $_[1]; }
$function = "XDIGITx"; chop $function;
for my $n (0..255) {
for $suffix ("_utf8", "_LC_utf8") {
my $char = chr($n);
utf8::upgrade($char);
$char = quotemeta $char if $char eq '\\' || $char eq "'";
$utf8_param_code = "0"; # 1/10 P,IOK
#
$utf8_param_code = 0; my $x = "$utf8_param_code";
study;
my $code;
set_code($code, "test_is${function}$suffix('$char',");
next if $code =~ /^test_isXDIGIT(_LC)?_utf8\('/;
print STDERR "mismatch: n=$n suffix=$suffix\n";
Dump $code;
}
}