From 29a7470516c0532e21c9cffde3adfb291d6453a0 Mon Sep 17 00:00:00 2001 From: Sergey Cherevko Date: Fri, 4 Aug 2023 17:32:23 +0300 Subject: [PATCH 1/3] Restore compatiblity wih Perl 5.26.0 --- src/if_perl.xs | 48 ------------------------------------------------ 1 file changed, 48 deletions(-) diff --git a/src/if_perl.xs b/src/if_perl.xs index 7b45033..2d2803c 100644 --- a/src/if_perl.xs +++ b/src/if_perl.xs @@ -37,13 +37,6 @@ #include "vim.h" -/* Work around for perl-5.18. - * Don't include "perl\lib\CORE\inline.h" for now, - * include it after Perl_sv_free2 is defined. */ -#ifdef DYNAMIC_PERL -# define PERL_NO_INLINE_FUNCTIONS -#endif - /* Work around for using MSVC and ActivePerl 5.18. */ #ifdef _MSC_VER # define __inline__ __inline @@ -616,47 +609,6 @@ static struct { {"", NULL}, }; -/* Work around for perl-5.18. - * For now, only the definitions of S_SvREFCNT_dec are needed in - * "perl\lib\CORE\inline.h". */ -# if (PERL_REVISION == 5) && (PERL_VERSION >= 18) -static void -S_SvREFCNT_dec(pTHX_ SV *sv) -{ - if (LIKELY(sv != NULL)) { - U32 rc = SvREFCNT(sv); - if (LIKELY(rc > 1)) - SvREFCNT(sv) = rc - 1; - else - Perl_sv_free2(aTHX_ sv, rc); - } -} -# endif - -/* perl-5.26 also needs S_TOPMARK and S_POPMARK. */ -# if (PERL_REVISION == 5) && (PERL_VERSION >= 26) -PERL_STATIC_INLINE I32 -S_TOPMARK(pTHX) -{ - DEBUG_s(DEBUG_v(PerlIO_printf(Perl_debug_log, - "MARK top %p %" IVdf "\n", - PL_markstack_ptr, - (IV)*PL_markstack_ptr))); - return *PL_markstack_ptr; -} - -PERL_STATIC_INLINE I32 -S_POPMARK(pTHX) -{ - DEBUG_s(DEBUG_v(PerlIO_printf(Perl_debug_log, - "MARK pop %p %" IVdf "\n", - (PL_markstack_ptr-1), - (IV)*(PL_markstack_ptr-1)))); - assert((PL_markstack_ptr > PL_markstack) || !"MARK underflow"); - return *PL_markstack_ptr--; -} -# endif - /* * Make all runtime-links of perl. * -- 2.39.2