--- JSON-XS/XS.xs 2007/07/10 15:45:34 1.53 +++ JSON-XS/XS.xs 2007/07/10 16:22:31 1.54 @@ -495,15 +495,15 @@ if (to_json) { + int count; dSP; ENTER; SAVETMPS; PUSHMARK (SP); XPUSHs (sv_bless (sv_2mortal (newRV_inc (sv)), SvSTASH (sv))); // calling with G_SCALAR ensures that we always get a 1 return value - // check anyways. PUTBACK; - assert (1 == call_sv ((SV *)GvCV (to_json), G_SCALAR)); + call_sv ((SV *)GvCV (to_json), G_SCALAR); SPAGAIN; // catch this surprisingly common error