Adding the failure diagnostic
[p5sagit/p5-mst-13.2.git] / t / op / misc.t
index e7f1623..3cfb667 100755 (executable)
@@ -724,9 +724,17 @@ sub DESTROY {
 EXPECT
 Bar=ARRAY(0x...)
 ########
-printf "%x %x", unpack "U*", sprintf "\x{1234}%s", "\x{5678}"
-EXPECT
-1234 5678
+# 20010407.008 sprintf removes utf8-ness
+$a = sprintf "\x{1234}";
+printf "%x %d\n", unpack("U*", $a), length($a);
+$a = sprintf "%s", "\x{5678}";
+printf "%x %d\n", unpack("U*", $a), length($a);
+$a = sprintf "\x{1234}%s", "\x{5678}";
+printf "%x %x %d\n", unpack("U*", $a), length($a);
+EXPECT
+1234 1
+5678 1
+1234 5678 2
 ########
 # keep this last - doesn't seem to work otherwise?
 eval "a.b.c.d.e.f;sub"