]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 9.0.2047: perl: warning about inconsistent dll linkage v9.0.2047
authorKen Takata <kentkt@csc.jp>
Wed, 18 Oct 2023 09:59:44 +0000 (11:59 +0200)
committerChristian Brabandt <cb@256bit.org>
Wed, 18 Oct 2023 09:59:44 +0000 (11:59 +0200)
Problem:  perl: warning about inconsistent dll linkage
Solution: suppress warning

Suppress warning C4273 (inconsistent DLL linkage).

Also adjust inconsistent use of const.

closes: #13369

Signed-off-by: Christian Brabandt <cb@256bit.org>
Co-authored-by: Ken Takata <kentkt@csc.jp>
src/if_perl.xs
src/version.c

index 312262ae3f40dcf5abd9979559a5012e7a0bea9b..d88c3f3d99cbea6d0f2149fe74c1069096fe2453 100644 (file)
 # define NO_THREAD_SAFE_LOCALE
 #endif
 
+#if defined(MSWIN) && defined(DYNAMIC_PERL)
+// Work around for warning C4273 (inconsistent DLL linkage).
+# define PERL_EXT_RE_BUILD
+#endif
+
 #ifdef __GNUC__
 # pragma GCC diagnostic push
 # pragma GCC diagnostic ignored "-Wunused-variable"
@@ -1483,7 +1488,7 @@ vim_IOLayer_init(void)
 
 # if (PERL_REVISION == 5) && (PERL_VERSION >= 18)
 #  undef Perl_sv_free2
-void Perl_sv_free2(pTHX_ SV* sv, const U32 refcnt)
+void Perl_sv_free2(pTHX_ SV *const sv, const U32 refcnt)
 {
     (*dll_Perl_sv_free2)(aTHX_ sv, refcnt);
 }
@@ -1519,7 +1524,7 @@ NV Perl_sv_2nv_flags(pTHX_ SV *const sv, const I32 flags)
 
 # ifdef PERL589_OR_LATER
 #  undef Perl_sv_2iv_flags
-IV Perl_sv_2iv_flags(pTHX_ SV* sv, I32 flags)
+IV Perl_sv_2iv_flags(pTHX_ SV *const sv, const I32 flags)
 {
     return (*dll_Perl_sv_2iv_flags)(aTHX_ sv, flags);
 }
index 1dba3bd2915844cd4477eda1016e021a2497aaa8..f839c28159d7fe106eb73e4a788cb98741d35d68 100644 (file)
@@ -704,6 +704,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    2047,
 /**/
     2046,
 /**/