Index: src/pmc/namespace.pmc =================================================================== --- src/pmc/namespace.pmc (revision 45671) +++ src/pmc/namespace.pmc (working copy) @@ -128,6 +128,7 @@ PMC * const classobj = VTABLE_get_class(interp, self); STRING * vtable_key = STRINGNULL; Parrot_Sub_attributes *sub; + INTVAL stored = 0; PMC_get_sub(interp, value, sub); @@ -152,6 +153,8 @@ /* Insert it. */ VTABLE_set_pmc_keyed_int(interp, vtable, sub->vtable_index, value); } + if (!(sub->comp_flags & SUB_COMP_FLAG_NSENTRY)) + stored = 1; } if (sub->comp_flags & SUB_COMP_FLAG_METHOD) { @@ -166,9 +169,12 @@ method_name = sub->method_name; } add_to_class(interp, nsinfo, classobj, method_name, value); + + if (!(sub->comp_flags & SUB_COMP_FLAG_NSENTRY)) + stored = 1; } - return 0; + return stored; } PARROT_WARN_UNUSED_RESULT Index: ext/nqp-rx/src/stage0/HLL-s0.pir =================================================================== --- ext/nqp-rx/src/stage0/HLL-s0.pir (revision 45671) +++ ext/nqp-rx/src/stage0/HLL-s0.pir (working copy) @@ -468,7 +468,7 @@ .end -.sub 'quotemod_check' :method +.sub 'quotemod_check' :method :nsentry .param string mod $P0 = find_dynamic_lex '%*QUOTEMOD' Index: t/pmc/namespace-subs.t =================================================================== --- t/pmc/namespace-subs.t (revision 45671) +++ t/pmc/namespace-subs.t (working copy) @@ -73,8 +73,7 @@ is($I1, 75, "Invoked stored method") $P2 = get_hll_global ['MethodTest'], 'methodtest' - todo(0, "Method not stored in namespace", "see TT #389") -# is_null($P2, "Method not stored in namespace") + is_null($P2, "Method not stored in namespace") .end .sub 'store_nsentry' Index: t/compilers/imcc/syn/subflags.t =================================================================== --- t/compilers/imcc/syn/subflags.t (revision 45671) +++ t/compilers/imcc/syn/subflags.t (working copy) @@ -69,7 +69,7 @@ isa_ok($P30, 'Sub', ":method sub found w/.const") $P0 = get_global 'method1' $I0 = isnull $P0 - todo($I0, ":method sub not found in namespace") + ok($I0, ":method sub not found in namespace") ## :subid subs .const 'Sub' $P40 = 'subid1'