From d7244c9a613101b97077ed781e11a729c347555c Mon Sep 17 00:00:00 2001 From: David Mitchell Date: Mon, 23 May 2016 15:45:20 +0100 Subject: [PATCH] mathoms.c: add explanation why fns must be kept See http://nntp.perl.org/group/perl.perl5.porters/236384. --- mathoms.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/mathoms.c b/mathoms.c index 6c60328..0ebf434 100644 --- a/mathoms.c +++ b/mathoms.c @@ -21,8 +21,16 @@ /* * This file contains mathoms, various binary artifacts from previous - * versions of Perl. For binary or source compatibility reasons, though, - * we cannot completely remove them from the core code. + * versions of Perl which we cannot completely remove from the core + * code. There are two reasons functions should be here: + * + * 1) A function has been been replaced by a macro within a minor release, + * so XS modules compiled against an older release will expect to + * still be able to link against the function + * 2) A function Perl_foo(...) with #define foo Perl_foo(aTHX_ ...) + * has been replaced by a macro, e.g. #define foo(...) foo_flags(...,0) + * but XS code may still explicitly use the long form, i.e. + * Perl_foo(aTHX_ ...) * * REMEMBER to update makedef.pl when adding a function to mathoms.c whose * name doesn't begin with "Perl_". -- 1.8.3.1