This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Make sure newCONSTSUB gets included on early perls
authorKarl Williamson <khw@cpan.org>
Mon, 15 Jul 2019 21:23:20 +0000 (15:23 -0600)
committerNicolas R <atoomic@cpan.org>
Fri, 27 Sep 2019 22:51:28 +0000 (16:51 -0600)
Otherwise functions that rely on it won't work.

(cherry picked from commit e139cb6c3b33fee6e7f100c55ab27223cf260c42)
Signed-off-by: Nicolas R <atoomic@cpan.org>
dist/Devel-PPPort/parts/inc/newCONSTSUB

index 336a8e0..57c3a47 100644 (file)
 
 newCONSTSUB
 
+=dontwarn
+
+NEED_newCONSTSUB    /* Because we define this weirdly */
+
 =implementation
 
 /* Hint: newCONSTSUB
@@ -22,6 +26,11 @@ newCONSTSUB
 
 /* newCONSTSUB from IO.xs is in the core starting with 5.004_63 */
 #if { VERSION < 5.004_63 } && { VERSION != 5.004_05 }
+
+/* And before that, we need to make sure this gets compiled for the functions
+ * that rely on it */
+#define NEED_newCONSTSUB
+
 #if { NEED newCONSTSUB }
 
 /* This is just a trick to avoid a dependency of newCONSTSUB on PL_parser */