Skip to content

Commit bd5d0b1

Browse files
committed
Make sure miniperl compiles with -DNO_SHORT_NAMES
This simple change makes the perl core compile even with this flag.
1 parent e42adc9 commit bd5d0b1

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

embed.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@
9191
!defined(PERL_WANT_VARARGS) */
9292
# endif /* !defined(PERL_NOCOMPAT) */
9393
#endif /* !defined(PERL_CORE) */
94-
#if !defined(PERL_NO_SHORT_NAMES)
94+
#if defined(PERL_CORE) || !defined(PERL_NO_SHORT_NAMES)
9595

9696
/* Hide global symbols */
9797

@@ -2488,6 +2488,6 @@
24882488
# else
24892489
# define get_context Perl_get_context
24902490
# endif
2491-
#endif /* !defined(PERL_NO_SHORT_NAMES) */
2491+
#endif /* defined(PERL_CORE) || !defined(PERL_NO_SHORT_NAMES) */
24922492

24932493
/* ex: set ro ft=c: */

regen/embed.pl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -703,7 +703,7 @@ sub generate_embed_h {
703703
* BEWARE that a bunch of macros don't have long names, so either must be
704704
* added or don't use them if you define this symbol */
705705
706-
#ifndef PERL_NO_SHORT_NAMES
706+
#if ! defined(PERL_NO_SHORT_NAMES) || defined(PERL_CORE)
707707
708708
/* Hide global symbols */
709709
@@ -715,7 +715,7 @@ sub generate_embed_h {
715715

716716
print $em <<~'END';
717717
718-
#endif /* #ifndef PERL_NO_SHORT_NAMES */
718+
#endif /* if !defined(PERL_NO_SHORT_NAMES) || defined(PERL_CORE) */
719719
720720
#if !defined(PERL_CORE)
721721
/* Compatibility stubs. Compile extensions with -DPERL_NOCOMPAT to

0 commit comments

Comments
 (0)