#define watch Perl_watch
#define whichsig Perl_whichsig
#define yyerror Perl_yyerror
-#if defined(USE_PURE_BISON)
+#ifdef USE_PURE_BISON
+#define yylex_r Perl_yylex_r
#define yylex Perl_yylex
#else
#define yylex Perl_yylex
#endif
-#define syylex S_syylex
#define yyparse Perl_yyparse
#define yywarn Perl_yywarn
#if defined(MYMALLOC)
#define watch(a) Perl_watch(aTHX_ a)
#define whichsig(a) Perl_whichsig(aTHX_ a)
#define yyerror(a) Perl_yyerror(aTHX_ a)
-#if defined(USE_PURE_BISON)
+#ifdef USE_PURE_BISON
+#define yylex_r(a,b) Perl_yylex_r(aTHX_ a,b)
#define yylex(a,b) Perl_yylex(aTHX_ a,b)
#else
#define yylex() Perl_yylex(aTHX)
#endif
-#define syylex() S_syylex(aTHX)
#define yyparse() Perl_yyparse(aTHX)
#define yywarn(a) Perl_yywarn(aTHX_ a)
#if defined(MYMALLOC)
#define whichsig Perl_whichsig
#define Perl_yyerror CPerlObj::Perl_yyerror
#define yyerror Perl_yyerror
-#if defined(USE_PURE_BISON)
+#ifdef USE_PURE_BISON
+#define Perl_yylex_r CPerlObj::Perl_yylex_r
+#define yylex_r Perl_yylex_r
#define Perl_yylex CPerlObj::Perl_yylex
#define yylex Perl_yylex
#else
#define Perl_yylex CPerlObj::Perl_yylex
#define yylex Perl_yylex
#endif
-#define S_syylex CPerlObj::S_syylex
-#define syylex S_syylex
#define Perl_yyparse CPerlObj::Perl_yyparse
#define yyparse Perl_yyparse
#define Perl_yywarn CPerlObj::Perl_yywarn
p |void |watch |char** addr
Ap |I32 |whichsig |char* sig
p |int |yyerror |char* s
-#if defined(USE_PURE_BISON)
+#ifdef USE_PURE_BISON
+p |int |yylex_r |YYSTYPE *lvalp|int *lcharp
p |int |yylex |YYSTYPE *lvalp|int *lcharp
#else
p |int |yylex
#endif
-sp |int |syylex
p |int |yyparse
p |int |yywarn |char* s
#if defined(MYMALLOC)
typedef SV* (CPERLscope(*re_intuit_string_t)) (pTHX_ regexp *prog);
typedef void (CPERLscope(*regfree_t)) (pTHX_ struct regexp* r);
-#ifdef USE_PURE_BISON
-int Perl_yylex(pTHX_ YYSTYPE *lvalp, int *lcharp);
-#endif
-
typedef void (*DESTRUCTORFUNC_NOCONTEXT_t) (void*);
typedef void (*DESTRUCTORFUNC_t) (pTHXo_ void*);
typedef void (*SVFUNC_t) (pTHXo_ SV*);
PERL_CALLCONV void Perl_watch(pTHX_ char** addr);
PERL_CALLCONV I32 Perl_whichsig(pTHX_ char* sig);
PERL_CALLCONV int Perl_yyerror(pTHX_ char* s);
-#if defined(USE_PURE_BISON)
+#ifdef USE_PURE_BISON
+PERL_CALLCONV int Perl_yylex_r(pTHX_ YYSTYPE *lvalp, int *lcharp);
PERL_CALLCONV int Perl_yylex(pTHX_ YYSTYPE *lvalp, int *lcharp);
#else
PERL_CALLCONV int Perl_yylex(pTHX);
#endif
-STATIC int S_syylex(pTHX);
PERL_CALLCONV int Perl_yyparse(pTHX);
PERL_CALLCONV int Perl_yywarn(pTHX_ char* s);
#if defined(MYMALLOC)
#endif
#ifdef USE_PURE_BISON
-#ifndef YYMAXLEVEL
-#define YYMAXLEVEL 100
-#endif
+# ifndef YYMAXLEVEL
+# define YYMAXLEVEL 100
+# endif
YYSTYPE* yylval_pointer[YYMAXLEVEL];
int* yychar_pointer[YYMAXLEVEL];
int yyactlevel = 0;
# define yychar (*yychar_pointer[yyactlevel])
# define PERL_YYLEX_PARAM yylval_pointer[yyactlevel],yychar_pointer[yyactlevel]
# undef yylex
-# define yylex() Perl_yylex(aTHX_ yylval_pointer[yyactlevel],yychar_pointer[yyactlevel])
+# define yylex() Perl_yylex_r(aTHX_ yylval_pointer[yyactlevel],yychar_pointer[yyactlevel])
#endif
#include "keywords.h"
if we already built the token before, use it.
*/
+#ifdef USE_PURE_BISON
#ifdef __SC__
-#pragma segment Perl_yylex
+#pragma segment Perl_yylex_r
#endif
int
-#ifdef USE_PURE_BISON
-Perl_yylex(pTHX_ YYSTYPE *lvalp, int *lcharp)
-#else
-Perl_yylex(pTHX)
-#endif
+Perl_yylex_r(pTHX_ YYSTYPE *lvalp, int *lcharp)
{
dTHR;
int r;
-#ifdef USE_PURE_BISON
yylval_pointer[yyactlevel] = lvalp;
yychar_pointer[yyactlevel] = lcharp;
yyactlevel++;
if (yyactlevel >= YYMAXLEVEL)
Perl_croak(aTHX_ "panic: YYMAXLEVEL");
-#endif
- r = S_syylex(aTHX);
+ r = Perl_yylex(aTHX);
-#ifdef USE_PURE_BISON
yyactlevel--;
-#endif
return r;
}
+#endif
-STATIC int
-S_syylex(pTHX) /* need to be separate from yylex for reentrancy */
+#ifdef __SC__
+#pragma segment Perl_yylex
+#endif
+
+int
+#ifdef USE_PURE_BISON
+Perl_yylex(pTHX_ YYSTYPE *lvalp, int *lcharp)
+#else
+Perl_yylex(pTHX)
+#endif
{
dTHR;
register char *s;