GV* iogv;
STRLEN packlen;
const char * const packname = SvPV_nomg_const(sv, packlen);
- bool packname_is_utf8 = FALSE;
+ const bool packname_is_utf8 = !!SvUTF8(sv);
const HE* const he =
- (const HE *)hv_common_key_len(
- PL_stashcache, packname,
- packlen * -(packname_is_utf8 = !!SvUTF8(sv)), 0, NULL, 0
+ (const HE *)hv_common(
+ PL_stashcache, NULL, packname, packlen,
+ packname_is_utf8 ? HVhek_UTF8 : 0, 0, NULL, 0
);
if (he) {
*Color::H1 = *Colour::H1{IO};
is(Colour::H1->getline(), <DATA>, 'read from a file');
+ { local $::TODO = "regression introduced when PL_stashcache was first added";
is(Color::H1->getline(), <DATA>,
'file handles take priority after typeglob assignment');
+ }
*Color::H1 = *CLOSED{IO};
{
+ local $::TODO = "regression introduced when PL_stashcache was first added";
no warnings 'io';
is(Color::H1->getline(), undef,
"assigning a closed a file handle doesn't change object resolution");