This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Fix C portability nit found by Jerry D. Hedden.
[perl5.git] / sv.c
diff --git a/sv.c b/sv.c
index f9546e1..a61f90a 100644 (file)
--- a/sv.c
+++ b/sv.c
@@ -7873,8 +7873,8 @@ Perl_sv_2cv(pTHX_ SV *sv, HV **const st, GV **const gvp, const I32 lref)
 
     default:
        if (SvROK(sv)) {
-           SvGETMAGIC(sv);
            SV * const *sp = &sv;       /* Used in tryAMAGICunDEREF macro. */
+           SvGETMAGIC(sv);
            tryAMAGICunDEREF(to_cv);
 
            sv = SvRV(sv);