#define PERL_ARENA_SIZE 4080
#endif
-/* enable ARENA_SETS by default, but allow disabling */
-#ifndef ARENASETS
-#define ARENASETS 1
-#endif
-
#endif /* PERL_CORE */
/* We no longer default to creating a new SV for GvSV.
Do this before embed. */
#ifndef PERL_CREATE_GVSV
-#define PERL_DONT_CREATE_GVSV
+# ifndef PERL_DONT_CREATE_GVSV
+# define PERL_DONT_CREATE_GVSV
+# endif
#endif
#if !defined(HAS_WAITPID) && !defined(HAS_WAIT4) || defined(HAS_WAITPID_RUNTIME)
*/
#if !defined(PERL_FOR_X2P) && !(defined(WIN32)||defined(VMS))
# include "embed.h"
+# ifndef PERL_MAD
+# undef op_getmad
+# define op_getmad(arg,pegop,slot) /**/
+# endif
#endif
#define MEM_SIZE Size_t
typedef MEM_SIZE STRLEN;
+#ifdef PERL_MAD
+typedef struct token TOKEN;
+typedef struct madprop MADPROP;
+typedef struct nexttoken NEXTTOKE;
+#endif
typedef struct op OP;
typedef struct cop COP;
typedef struct unop UNOP;
#if defined(VMS)
# include "vmsish.h"
# include "embed.h"
+# ifndef PERL_MAD
+# undef op_getmad
+# define op_getmad(arg,pegop,slot) /**/
+# endif
# define ISHISH "vms"
#endif
#ifdef __SYMBIAN32__
# include "symbian/symbianish.h"
# include "embed.h"
+# ifndef PERL_MAD
+# undef op_getmad
+# define op_getmad(arg,pegop,slot) /**/
+# endif
# define ISHISH "symbian"
#endif
# define NORETURN_FUNCTION_END /* NOTREACHED */ return 0
#endif
-#ifdef HASBUILTIN_EXPECT
+#ifdef HAS_BUILTIN_EXPECT
# define EXPECT(expr,val) __builtin_expect(expr,val)
#else
# define EXPECT(expr,val) (expr)
#endif
#define LIKELY(cond) EXPECT(cond,1)
#define UNLIKELY(cond) EXPECT(cond,0)
+#ifdef HAS_BUILTIN_CHOOSE_EXPR
+/* placeholder */
+#endif
/* Some unistd.h's give a prototype for pause() even though
HAS_PAUSE ends up undefined. This causes the #define
# define USE_HASH_SEED
#endif
+/* Win32 defines a type 'WORD' in windef.h. This conflicts with the enumerator
+ * 'WORD' defined in perly.h. The yytokentype enum is only a debugging aid, so
+ * it's not really needed.
+ */
+#if defined(WIN32)
+# define YYTOKENTYPE
+#endif
+#include "perly.h"
+
+#ifdef PERL_MAD
+struct nexttoken {
+ YYSTYPE next_val; /* value of next token, if any */
+ I32 next_type; /* type of next token */
+ MADPROP *next_mad; /* everything else about that token */
+};
+#endif
+
#include "regexp.h"
#include "sv.h"
#include "util.h"
#endif
#endif
-/* Win32 defines a type 'WORD' in windef.h. This conflicts with the enumerator
- * 'WORD' defined in perly.h. The yytokentype enum is only a debugging aid, so
- * it's not really needed.
- */
-#if defined(WIN32)
-# define YYTOKENTYPE
-#endif
-#include "perly.h"
-
#define LEX_NOTPARSING 11 /* borrowed from toke.c */
typedef enum {
#if !defined(PERL_FOR_X2P)
# include "embedvar.h"
#endif
+#ifndef PERL_MAD
+# undef PL_madskills
+# undef PL_xmlfp
+# define PL_madskills 0
+# define PL_xmlfp 0
+#endif
/* Now include all the 'global' variables
* If we don't have threads or multiple interpreters
#if defined(WIN32)
/* Now all the config stuff is setup we can include embed.h */
# include "embed.h"
+# ifndef PERL_MAD
+# undef op_getmad
+# define op_getmad(arg,pegop,slot) /**/
+# endif
#endif
#ifndef PERL_GLOBAL_STRUCT