1170 1171 { 1172 # gh #17221 1173 my ($off1, $off2); 1174 my $x = eval { sprintf "%n0%n\x{100}", $off1, $off2 }; 1175 is($@, "", "no exception"); 1176 is($x, "0\x{100}", "reasonable result"); 1177 is($off1, 0, "offset at start"); 1178 is($off2, 1, "offset after 0"); 1179 } 1180 #### 173 # In each of the following lines, there are three required fields:... #### 481 >%s< >sprintf('%%n%n %d', $n, $n)< >%n 2< >Slight sneakiness to test %n< 482 >%s< >$n="abc"; sprintf(' %n%s', substr($n,1,1), $n)< > a1c< >%n w/magic< 483 >%s< >no warnings; sprintf('%s%n', chr(256)x5, $n),$n< >5< >Unicode %n< 484 >