- STATIC OP *scalar_util_reftype(pTHX) {
- dSP;
- dMARK;
- SV *sv = POPs;
- if (SvMAGICAL(sv))
- mg_get(sv);
- if (SvROK(sv))
- PUSHs(sv_reftype(SvRV(sv), 0));
- else
- PUSHs(&PL_sv_undef);
- RETURN;
+ STATIC OP *sub_recall_call(pTHX_ OP *, void *ud_) {
+ OP *ex_list, *pushmark, *refgen, *gvop, *last_arg, *rv2cv;
+
+ ex_list = cUNOPo->op_first;
+ pushmark = cUNOPx(ex_list)->op_first;
+ refgen = pushmark->op_sibling;
+ gvop = sub_op_study(o, &last_arg, &rv2cv);
+
+ /* Replace the function name by the refgen that contains
+ the anon sub */
+ op_free(rv2cv);
+ last_arg->op_sibling = refgen;
+ pushmark->op_sibling = refgen->op_sibling;
+ refgen->op_sibling = NULL;
+
+ return o;