t/uni/overload.t See if Unicode overloading works
t/uni/package.t See if Unicode in package declarations works
t/uni/parser.t See if Unicode in the parser works in edge cases.
+t/uni/select.t See if Unicode filehandles aren't mangled by select()
t/uni/sprintf.t See if Unicode sprintf works
t/uni/stash.t See if Unicode stashes work
t/uni/tie.t See if Unicode tie works
if (! hv)
XPUSHs(&PL_sv_undef);
else {
- GV * const * const gvp = (GV**)hv_fetch(hv, GvNAME(egv), GvNAMELEN(egv), FALSE);
+ GV * const * const gvp = (GV**)hv_fetch(hv, GvNAME(egv), HEK_UTF8(GvNAME_HEK(egv)) ? -GvNAMELEN(egv) : GvNAMELEN(egv), FALSE);
if (gvp && *gvp == egv) {
gv_efullname4(TARG, PL_defoutgv, NULL, TRUE);
XPUSHTARG;
--- /dev/null
+#!./perl
+
+#
+# Tests whenever the return value of select(FH) is correctly encoded.
+#
+
+BEGIN {
+ chdir 't' if -d 't';
+ @INC = '../lib';
+ require './test.pl';
+}
+
+use utf8;
+use open qw( :utf8 :std );
+
+plan( tests => 5 );
+
+open DÙP, ">&", *STDERR;
+open $dùp, ">&", *STDOUT;
+open 둪, ">&", *STDERR;
+open $ᛞ웊, ">&", *STDOUT;
+
+is select(DÙP), "main::STDOUT";
+is select($dùp), "main::DÙP";
+
+TODO: {
+ local $TODO = "Scalar filehandles not yet clean";
+ is select(둪), "main::dùp";
+}
+
+is select($ᛞ웊), "main::둪";
+TODO: {
+ local $TODO = "Scalar filehandles not yet clean";
+ is select(STDOUT), "main::ᛞ웊";
+}