mirror of
https://github.com/Perl/perl5.git
synced 2026-01-26 08:38:23 +00:00
Add some duplication to makedef.pl from perl.h
There is unfortunately some duplication required in makedef.pl copied from perl.h. This adds some more for two variables, required for the next commit, which will remove far more lines from makedef.pl than this adds
This commit is contained in:
parent
935cdb76e8
commit
5034cac71e
13
makedef.pl
13
makedef.pl
@ -211,6 +211,15 @@ if ($define{MULTIPLICITY} && ( $define{USE_POSIX_2008_LOCALE}
|
||||
$define{USE_PERL_SWITCH_LOCALE_CONTEXT} = 1;
|
||||
}
|
||||
|
||||
# enable PERL_COPY_ON_WRITE by default
|
||||
$define{PERL_COPY_ON_WRITE} = 1 unless $define{PERL_NO_COW};
|
||||
if ($define{PERL_COPY_ON_WRITE}) {
|
||||
$define{PERL_ANY_COW} = 1;
|
||||
}
|
||||
else {
|
||||
$define{PERL_SAWAMPERSAND} = 1;
|
||||
}
|
||||
|
||||
# perl.h logic duplication ends
|
||||
#==========================================================================
|
||||
|
||||
@ -371,10 +380,6 @@ else {
|
||||
);
|
||||
}
|
||||
|
||||
if (!$define{'PERL_COPY_ON_WRITE'} || $define{'PERL_NO_COW'}) {
|
||||
++$skip{Perl_sv_setsv_cow};
|
||||
}
|
||||
|
||||
unless ($define{PERL_SAWAMPERSAND}) {
|
||||
++$skip{PL_sawampersand};
|
||||
}
|
||||
|
||||
22
perl.h
22
perl.h
@ -1325,6 +1325,17 @@ typedef enum {
|
||||
# endif
|
||||
#endif /* End of USE_LOCALE */
|
||||
|
||||
/* enable PERL_COPY_ON_WRITE by default */
|
||||
#if !defined(PERL_COPY_ON_WRITE) && !defined(PERL_NO_COW)
|
||||
# define PERL_COPY_ON_WRITE
|
||||
#endif
|
||||
|
||||
#ifdef PERL_COPY_ON_WRITE
|
||||
# define PERL_ANY_COW
|
||||
#else
|
||||
# define PERL_SAWAMPERSAND
|
||||
#endif
|
||||
|
||||
/* end of makedef.pl logic duplication
|
||||
* ========================================================================= */
|
||||
|
||||
@ -3218,17 +3229,6 @@ typedef struct padname PADNAME;
|
||||
# define PERL_OP_PARENT
|
||||
#endif
|
||||
|
||||
/* enable PERL_COPY_ON_WRITE by default */
|
||||
#if !defined(PERL_COPY_ON_WRITE) && !defined(PERL_NO_COW)
|
||||
# define PERL_COPY_ON_WRITE
|
||||
#endif
|
||||
|
||||
#ifdef PERL_COPY_ON_WRITE
|
||||
# define PERL_ANY_COW
|
||||
#else
|
||||
# define PERL_SAWAMPERSAND
|
||||
#endif
|
||||
|
||||
#if defined(PERL_DEBUG_READONLY_OPS) && !defined(USE_ITHREADS)
|
||||
# error PERL_DEBUG_READONLY_OPS only works with ithreads
|
||||
#endif
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user