This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Perl_load_module() no longer moves the current stack, so no need to save it.
[perl5.git] / ext / PerlIO-encoding / encoding.xs
index a0415d0..f7b5a4c 100644 (file)
@@ -650,11 +650,9 @@ BOOT:
        Perl_warner(aTHX_ packWARN(WARN_IO), ":encoding without 'use Encode'");
 #endif
        ENTER;
-       /* Encode needs a lot of stack - it is likely to move ... */
-       PUTBACK;
        /* The SV is magically freed by load_module */
        load_module(PERL_LOADMOD_NOIMPORT, newSVpvn("Encode", 6), Nullsv, Nullsv);
-       SPAGAIN;
+       assert(sp == PL_stack_sp);
        LEAVE;
     }
     PUSHMARK(sp);