LibreOffice Module hwpfilter (master) 1
Macros | Functions | Variables
grammar.cxx File Reference
#include <vector>
#include <stdlib.h>
#include <string.h>
#include "grammar.hxx"
#include "lexer.hxx"
#include "nodes.h"
#include "grammar.h"
#include <stdio.h>
Include dependency graph for grammar.cxx:

Go to the source code of this file.

Macros

#define YYMAXDEPTH   0
 
#define YYFINAL   102
 
#define YYFLAG   -32768
 
#define YYNTBASE   43
 
#define YYTRANSLATE(x)   (static_cast<unsigned>(x) <= 285 ? yytranslate[x] : 66)
 
#define YYLAST   457
 
#define YYEMPTY   -2
 
#define YYEOF   0
 
#define YYACCEPT   goto yyacceptlab
 
#define YYABORT   goto yyabortlab
 
#define YYTERROR   1
 
#define YYLEX   yylex()
 
#define YYINITDEPTH   200
 
#define YYMAXDEPTH   10000
 
#define YYPARSE_PARAM_ARG
 
#define YYPARSE_PARAM_DECL
 

Functions

static void yyerror (const char *)
 
static int debug (const char *format,...)
 
static int yyparse (YYPARSE_PARAM_ARG) YYPARSE_PARAM_DECL
 
NodemainParse (const char *_code)
 

Variables

std::vector< std::unique_ptr< Node > > nodelist
 
static Nodetop =nullptr
 
const char yytranslate []
 
const short yyr1 []
 
const short yyr2 []
 
const short yydefact []
 
const short yydefgoto []
 
const short yypact []
 
const short yypgoto []
 
const short yytable []
 
const short yycheck []
 
static int yychar
 
YYSTYPE yylval
 
static int yynerrs
 

Macro Definition Documentation

◆ YYABORT

#define YYABORT   goto yyabortlab

Definition at line 295 of file grammar.cxx.

◆ YYACCEPT

#define YYACCEPT   goto yyacceptlab

Definition at line 294 of file grammar.cxx.

◆ YYEMPTY

#define YYEMPTY   -2

Definition at line 292 of file grammar.cxx.

◆ YYEOF

#define YYEOF   0

Definition at line 293 of file grammar.cxx.

◆ YYFINAL

#define YYFINAL   102

Definition at line 56 of file grammar.cxx.

◆ YYFLAG

#define YYFLAG   -32768

Definition at line 57 of file grammar.cxx.

◆ YYINITDEPTH

#define YYINITDEPTH   200

Definition at line 312 of file grammar.cxx.

◆ YYLAST

#define YYLAST   457

Definition at line 158 of file grammar.cxx.

◆ YYLEX

#define YYLEX   yylex()

Definition at line 299 of file grammar.cxx.

◆ YYMAXDEPTH [1/2]

#define YYMAXDEPTH   0

Definition at line 323 of file grammar.cxx.

◆ YYMAXDEPTH [2/2]

#define YYMAXDEPTH   10000

Definition at line 323 of file grammar.cxx.

◆ YYNTBASE

#define YYNTBASE   43

Definition at line 58 of file grammar.cxx.

◆ YYPARSE_PARAM_ARG

#define YYPARSE_PARAM_ARG

Definition at line 326 of file grammar.cxx.

◆ YYPARSE_PARAM_DECL

#define YYPARSE_PARAM_DECL

Definition at line 327 of file grammar.cxx.

◆ YYTERROR

#define YYTERROR   1

Definition at line 297 of file grammar.cxx.

◆ YYTRANSLATE

#define YYTRANSLATE (   x)    (static_cast<unsigned>(x) <= 285 ? yytranslate[x] : 66)

Definition at line 60 of file grammar.cxx.

Function Documentation

◆ debug()

int debug ( const char *  format,
  ... 
)
static

Definition at line 912 of file grammar.cxx.

Referenced by yyparse().

◆ mainParse()

Node * mainParse ( const char *  _code)

Definition at line 890 of file grammar.cxx.

References deinitFlex(), initFlex(), top, and yyparse().

Referenced by Formula::parse().

◆ yyerror()

static void yyerror ( const char *  )
static

Definition at line 903 of file grammar.cxx.

References nodelist, and top.

Referenced by yyparse().

◆ yyparse()

static int yyparse ( YYPARSE_PARAM_ARG  )
static

Variable Documentation

◆ nodelist

std::vector<std::unique_ptr<Node> > nodelist

Definition at line 40 of file grammar.cxx.

Referenced by Formula::parse(), yyerror(), and yyparse().

◆ top

Node* top =nullptr
static

Definition at line 44 of file grammar.cxx.

Referenced by mainParse(), yyerror(), and yyparse().

◆ yychar

int yychar
static

Definition at line 303 of file grammar.cxx.

Referenced by yyparse().

◆ yycheck

const short yycheck[]

Definition at line 210 of file grammar.cxx.

Referenced by yyparse().

◆ yydefact

const short yydefact[]
Initial value:
= { 0,
46, 1, 4, 10, 9, 14, 2, 3, 5, 6,
0, 0, 12, 13, 48, 7, 8, 17, 11, 0,
0, 0, 26, 16, 15, 0, 0, 18, 70, 0,
63, 62, 61, 64, 65, 66, 0, 69, 0, 67,
68, 71, 72, 55, 56, 58, 59, 0, 0, 50,
0, 0, 52, 54, 24, 20, 21, 22, 23, 36,
0, 38, 0, 19, 0, 47, 49, 0, 60, 0,
0, 40, 0, 0, 51, 44, 53, 25, 35, 0,
37, 0, 33, 34, 57, 61, 41, 42, 39, 0,
31, 27, 28, 29, 30, 0, 45, 32, 43, 0,
0, 0
}

Definition at line 117 of file grammar.cxx.

Referenced by yyparse().

◆ yydefgoto

const short yydefgoto[]
Initial value:
= { 28,
29, 30, 84, 31, 32, 33, 51, 34, 35, 36,
37, 38, 39, 40, 41, 42, 43, 100, 44, 45,
46, 47
}

Definition at line 131 of file grammar.cxx.

Referenced by yyparse().

◆ yylval

YYSTYPE yylval

Definition at line 304 of file grammar.cxx.

Referenced by while(), and yyparse().

◆ yynerrs

int yynerrs
static

Definition at line 307 of file grammar.cxx.

Referenced by yyparse().

◆ yypact

const short yypact[]
Initial value:
= { 393,
-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
-30, -19,-32768,-32768,-32768,-32768,-32768,-32768,-32768, -19,
-19, -3,-32768,-32768,-32768, 290, 107,-32768, 425, 393,
-32768,-32768,-32768,-32768,-32768,-32768, -19,-32768, -19,-32768,
-32768,-32768,-32768, -20,-32768, 393, -21, 218, 107,-32768,
-19, -19, -19,-32768, -15,-32768,-32768,-32768,-32768,-32768,
325,-32768, 70,-32768, 360,-32768,-32768, 393, -21, 393,
393,-32768, 254, 144,-32768,-32768,-32768,-32768,-32768, 393,
-32768, -25,-32768,-32768,-32768, -31, -21, -21,-32768, 181,
-14,-32768,-32768,-32768,-32768, -19,-32768,-32768,-32768, 22,
23,-32768
}

Definition at line 137 of file grammar.cxx.

Referenced by yyparse().

◆ yypgoto

const short yypgoto[]
Initial value:
= { -2,
-32768,-32768,-32768,-32768,-32768, -11,-32768,-32768,-32768,-32768,
-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768, -33,
-24, -27
}

Definition at line 151 of file grammar.cxx.

Referenced by yyparse().

◆ yyr1

const short yyr1[]
Initial value:
= { 0,
43, 43, 43, 43, 43, 43, 43, 43, 43, 43,
43, 43, 43, 43, 43, 43, 43, 44, 44, 45,
45, 45, 45, 45, 45, 45, 46, 46, 46, 46,
46, 46, 46, 47, 48, 48, 49, 49, 50, 50,
51, 51, 51, 52, 53, 54, 55, 56, 57, 58,
58, 59, 59, 60, 61, 62, 62, 63, 64, 64,
65, 65, 65, 65, 65, 65, 65, 65, 65, 65,
65, 65
}

Definition at line 95 of file grammar.cxx.

Referenced by yyparse().

◆ yyr2

const short yyr2[]
Initial value:
= { 0,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 2, 2,
2, 2, 2, 2, 3, 1, 2, 2, 2, 2,
2, 3, 1, 3, 3, 2, 3, 2, 3, 2,
3, 3, 5, 3, 5, 1, 2, 1, 2, 2,
3, 2, 3, 2, 1, 1, 3, 1, 1, 2,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1
}

Definition at line 106 of file grammar.cxx.

Referenced by yyparse().

◆ yytable

const short yytable[]

Definition at line 161 of file grammar.cxx.

Referenced by yyparse().

◆ yytranslate

const char yytranslate[]

Definition at line 62 of file grammar.cxx.