summaryrefslogtreecommitdiff
path: root/perl.h
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2011-04-30 23:01:07 +0100
committerNicholas Clark <nick@ccl4.org>2011-06-12 16:15:21 +0200
commit58f645e20791a7788fcb38189895a712d5c53419 (patch)
tree768a485e3238e8b68abbf92cefed82fcb253b446 /perl.h
parent8790f825d5f6ff0beed9873a34e145cf35e3ce5c (diff)
downloadperl-58f645e20791a7788fcb38189895a712d5c53419.tar.gz
Move PL_{No,Yes,hexdigit} from perlvars.h to perl.h, as all are const char[]
They were converted in perl.h from const char[] to #define in 31fb120917c4f65d, then re-instated as const char[], but in perlvars.h, in 3fe35a814d0a98f4. There's no need for compile-time constants to jump through the hoops of perlvars.h, even for Symbian, as the various "EXTCONST" variables already in perl.h demonstrate. These were the only 3 users of the the PERLVARISC macro, so eliminate that, and all related code.
Diffstat (limited to 'perl.h')
-rw-r--r--perl.h10
1 files changed, 7 insertions, 3 deletions
diff --git a/perl.h b/perl.h
index 0be51a4062..5bbda62cb3 100644
--- a/perl.h
+++ b/perl.h
@@ -4244,6 +4244,13 @@ EXTCONST char PL_no_localize_ref[]
EXTCONST char PL_memory_wrap[]
INIT("panic: memory wrap");
+EXTCONST char PL_Yes[]
+ INIT("1");
+EXTCONST char PL_No[]
+ INIT("");
+EXTCONST char PL_hexdigit[]
+ INIT("0123456789abcdef0123456789ABCDEF");
+
#ifdef CSH
EXTCONST char PL_cshname[]
INIT(CSH);
@@ -4887,7 +4894,6 @@ struct interpreter {
# define PERLVARA(var,n,type) type var[n];
# define PERLVARI(var,type,init) type var;
# define PERLVARIC(var,type,init) type var;
-# define PERLVARISC(var,init) const char var[sizeof(init)];
struct interpreter {
# include "intrpvar.h"
@@ -4923,7 +4929,6 @@ struct perl_vars *PL_VarsPtr;
# undef PERLVARA
# undef PERLVARI
# undef PERLVARIC
-# undef PERLVARISC
#endif /* MULTIPLICITY */
@@ -4974,7 +4979,6 @@ struct tempsym; /* defined in pp_pack.c */
#define PERLVARA(var,n,type) EXT type PL_##var[n];
#define PERLVARI(var,type,init) EXT type PL_##var INIT(init);
#define PERLVARIC(var,type,init) EXTCONST type PL_##var INIT(init);
-#define PERLVARISC(var,init) EXTCONST char PL_##var[sizeof(init)] INIT(init);
#if !defined(MULTIPLICITY)
START_EXTERN_C