Volksdata 1.0b7
RDF library
Loading...
Searching...
No Matches
grammar_ttl.c File Reference
#include "volksdata/codec.h"
#include <assert.h>
#include <stdio.h>
Include dependency graph for grammar_ttl.c:

Go to the source code of this file.

Data Structures

union  YYMINORTYPE
struct  yyStackEntry
struct  yyParser

Macros

#define T_PERIOD   1
 Lemon parser grammar for Turtle.
#define T_SEMICOLON   2
#define T_COMMA   3
#define T_STRING   4
#define T_INTEGER   5
#define T_DOUBLE   6
#define T_DECIMAL   7
#define T_BOOLEAN   8
#define T_BNODE_ID   9
#define T_NSIRI   10
#define T_IRIREF   11
#define T_LANGTAG   12
#define T_PREFIX   13
#define T_COLON   14
#define T_EOF   15
#define T_WS   16
#define T_BASE   17
#define T_RDF_TYPE   18
#define T_DTYPE_MARKER   19
#define T_ANON   20
#define T_LBRACKET   21
#define T_RBRACKET   22
#define T_LPAREN   23
#define T_RPAREN   24
#define INTERFACE   1
#define YYCODETYPE   unsigned char
#define YYNOCODE   42
#define YYACTIONTYPE   unsigned char
#define TTLParseTOKENTYPE   char *
#define YYSTACKDEPTH   100
#define TTLParseARG_SDECL   VOLK_TTLParserState *state ;
#define TTLParseARG_PDECL   , VOLK_TTLParserState *state
#define TTLParseARG_PARAM   ,state
#define TTLParseARG_FETCH   VOLK_TTLParserState *state =yypParser->state ;
#define TTLParseARG_STORE   yypParser->state =state ;
#define TTLParseCTX_SDECL
#define TTLParseCTX_PDECL
#define TTLParseCTX_PARAM
#define TTLParseCTX_FETCH
#define TTLParseCTX_STORE
#define YYNSTATE   28
#define YYNRULE   41
#define YYNRULE_WITH_ACTION   27
#define YYNTOKEN   25
#define YY_MAX_SHIFT   27
#define YY_MIN_SHIFTREDUCE   63
#define YY_MAX_SHIFTREDUCE   103
#define YY_ERROR_ACTION   104
#define YY_ACCEPT_ACTION   105
#define YY_NO_ACTION   106
#define YY_MIN_REDUCE   107
#define YY_MAX_REDUCE   147
#define YY_NLOOKAHEAD   ((int)(sizeof(yy_lookahead)/sizeof(yy_lookahead[0])))
#define yytestcase(X)
#define YY_ACTTAB_COUNT   (115)
#define YY_SHIFT_COUNT   (27)
#define YY_SHIFT_MIN   (0)
#define YY_SHIFT_MAX   (108)
#define YY_REDUCE_COUNT   (15)
#define YY_REDUCE_MIN   (-25)
#define YY_REDUCE_MAX   (64)
#define YYMALLOCARGTYPE   size_t
#define TOKEN   yyminor

Functions

void TTLParseTrace (FILE *TraceFILE, char *zTracePrompt)
void TTLParseInit (void *yypRawParser TTLParseCTX_PDECL)
void * TTLParseAlloc (void *(*mallocProc)(YYMALLOCARGTYPE) TTLParseCTX_PDECL)
void TTLParseFinalize (void *p)
void TTLParseFree (void *p, void(*freeProc)(void *))
void TTLParse (void *yyp, int yymajor, TTLParseTOKENTYPE yyminor TTLParseARG_PDECL)
int TTLParseFallback (int iToken)

Macro Definition Documentation

◆ T_PERIOD

#define T_PERIOD   1

Lemon parser grammar for Turtle.

The lemon parser generator executable must be in your PATH: https://sqlite.org/src/doc/trunk/doc/lemon.html

TTL EBNF: https://www.w3.org/TeamSubmission/turtle/#sec-grammar-grammar

Definition at line 18 of file grammar_ttl.c.

◆ T_SEMICOLON

#define T_SEMICOLON   2

Definition at line 19 of file grammar_ttl.c.

◆ T_COMMA

#define T_COMMA   3

Definition at line 20 of file grammar_ttl.c.

◆ T_STRING

#define T_STRING   4

Definition at line 21 of file grammar_ttl.c.

◆ T_INTEGER

#define T_INTEGER   5

Definition at line 22 of file grammar_ttl.c.

◆ T_DOUBLE

#define T_DOUBLE   6

Definition at line 23 of file grammar_ttl.c.

◆ T_DECIMAL

#define T_DECIMAL   7

Definition at line 24 of file grammar_ttl.c.

◆ T_BOOLEAN

#define T_BOOLEAN   8

Definition at line 25 of file grammar_ttl.c.

◆ T_BNODE_ID

#define T_BNODE_ID   9

Definition at line 26 of file grammar_ttl.c.

◆ T_NSIRI

#define T_NSIRI   10

Definition at line 27 of file grammar_ttl.c.

◆ T_IRIREF

#define T_IRIREF   11

Definition at line 28 of file grammar_ttl.c.

◆ T_LANGTAG

#define T_LANGTAG   12

Definition at line 29 of file grammar_ttl.c.

◆ T_PREFIX

#define T_PREFIX   13

Definition at line 30 of file grammar_ttl.c.

◆ T_COLON

#define T_COLON   14

Definition at line 31 of file grammar_ttl.c.

◆ T_EOF

#define T_EOF   15

Definition at line 32 of file grammar_ttl.c.

◆ T_WS

#define T_WS   16

Definition at line 33 of file grammar_ttl.c.

◆ T_BASE

#define T_BASE   17

Definition at line 34 of file grammar_ttl.c.

◆ T_RDF_TYPE

#define T_RDF_TYPE   18

Definition at line 35 of file grammar_ttl.c.

◆ T_DTYPE_MARKER

#define T_DTYPE_MARKER   19

Definition at line 36 of file grammar_ttl.c.

◆ T_ANON

#define T_ANON   20

Definition at line 37 of file grammar_ttl.c.

◆ T_LBRACKET

#define T_LBRACKET   21

Definition at line 38 of file grammar_ttl.c.

◆ T_RBRACKET

#define T_RBRACKET   22

Definition at line 39 of file grammar_ttl.c.

◆ T_LPAREN

#define T_LPAREN   23

Definition at line 40 of file grammar_ttl.c.

◆ T_RPAREN

#define T_RPAREN   24

Definition at line 41 of file grammar_ttl.c.

◆ INTERFACE

#define INTERFACE   1

Definition at line 97 of file grammar_ttl.c.

◆ YYCODETYPE

#define YYCODETYPE   unsigned char

Definition at line 100 of file grammar_ttl.c.

◆ YYNOCODE

#define YYNOCODE   42

Definition at line 101 of file grammar_ttl.c.

◆ YYACTIONTYPE

#define YYACTIONTYPE   unsigned char

Definition at line 102 of file grammar_ttl.c.

◆ TTLParseTOKENTYPE

#define TTLParseTOKENTYPE   char *

Definition at line 103 of file grammar_ttl.c.

◆ YYSTACKDEPTH

#define YYSTACKDEPTH   100

Definition at line 113 of file grammar_ttl.c.

◆ TTLParseARG_SDECL

#define TTLParseARG_SDECL   VOLK_TTLParserState *state ;

Definition at line 115 of file grammar_ttl.c.

◆ TTLParseARG_PDECL

#define TTLParseARG_PDECL   , VOLK_TTLParserState *state

Definition at line 116 of file grammar_ttl.c.

◆ TTLParseARG_PARAM

#define TTLParseARG_PARAM   ,state

Definition at line 117 of file grammar_ttl.c.

◆ TTLParseARG_FETCH

#define TTLParseARG_FETCH   VOLK_TTLParserState *state =yypParser->state ;

Definition at line 118 of file grammar_ttl.c.

◆ TTLParseARG_STORE

#define TTLParseARG_STORE   yypParser->state =state ;

Definition at line 119 of file grammar_ttl.c.

◆ TTLParseCTX_SDECL

#define TTLParseCTX_SDECL

Definition at line 120 of file grammar_ttl.c.

◆ TTLParseCTX_PDECL

#define TTLParseCTX_PDECL

Definition at line 121 of file grammar_ttl.c.

◆ TTLParseCTX_PARAM

#define TTLParseCTX_PARAM

Definition at line 122 of file grammar_ttl.c.

◆ TTLParseCTX_FETCH

#define TTLParseCTX_FETCH

Definition at line 123 of file grammar_ttl.c.

◆ TTLParseCTX_STORE

#define TTLParseCTX_STORE

Definition at line 124 of file grammar_ttl.c.

◆ YYNSTATE

#define YYNSTATE   28

Definition at line 125 of file grammar_ttl.c.

◆ YYNRULE

#define YYNRULE   41

Definition at line 126 of file grammar_ttl.c.

◆ YYNRULE_WITH_ACTION

#define YYNRULE_WITH_ACTION   27

Definition at line 127 of file grammar_ttl.c.

◆ YYNTOKEN

#define YYNTOKEN   25

Definition at line 128 of file grammar_ttl.c.

◆ YY_MAX_SHIFT

#define YY_MAX_SHIFT   27

Definition at line 129 of file grammar_ttl.c.

◆ YY_MIN_SHIFTREDUCE

#define YY_MIN_SHIFTREDUCE   63

Definition at line 130 of file grammar_ttl.c.

◆ YY_MAX_SHIFTREDUCE

#define YY_MAX_SHIFTREDUCE   103

Definition at line 131 of file grammar_ttl.c.

◆ YY_ERROR_ACTION

#define YY_ERROR_ACTION   104

Definition at line 132 of file grammar_ttl.c.

◆ YY_ACCEPT_ACTION

#define YY_ACCEPT_ACTION   105

Definition at line 133 of file grammar_ttl.c.

◆ YY_NO_ACTION

#define YY_NO_ACTION   106

Definition at line 134 of file grammar_ttl.c.

◆ YY_MIN_REDUCE

#define YY_MIN_REDUCE   107

Definition at line 135 of file grammar_ttl.c.

◆ YY_MAX_REDUCE

#define YY_MAX_REDUCE   147

Definition at line 136 of file grammar_ttl.c.

◆ YY_NLOOKAHEAD

#define YY_NLOOKAHEAD   ((int)(sizeof(yy_lookahead)/sizeof(yy_lookahead[0])))

Definition at line 138 of file grammar_ttl.c.

◆ yytestcase

#define yytestcase ( X)

Definition at line 149 of file grammar_ttl.c.

◆ YY_ACTTAB_COUNT

#define YY_ACTTAB_COUNT   (115)

Definition at line 203 of file grammar_ttl.c.

◆ YY_SHIFT_COUNT

#define YY_SHIFT_COUNT   (27)

Definition at line 234 of file grammar_ttl.c.

◆ YY_SHIFT_MIN

#define YY_SHIFT_MIN   (0)

Definition at line 235 of file grammar_ttl.c.

◆ YY_SHIFT_MAX

#define YY_SHIFT_MAX   (108)

Definition at line 236 of file grammar_ttl.c.

◆ YY_REDUCE_COUNT

#define YY_REDUCE_COUNT   (15)

Definition at line 242 of file grammar_ttl.c.

◆ YY_REDUCE_MIN

#define YY_REDUCE_MIN   (-25)

Definition at line 243 of file grammar_ttl.c.

◆ YY_REDUCE_MAX

#define YY_REDUCE_MAX   (64)

Definition at line 244 of file grammar_ttl.c.

◆ YYMALLOCARGTYPE

#define YYMALLOCARGTYPE   size_t

Definition at line 493 of file grammar_ttl.c.

◆ TOKEN

#define TOKEN   yyminor

Function Documentation

◆ TTLParseTrace()

void TTLParseTrace ( FILE * TraceFILE,
char * zTracePrompt )

Definition at line 348 of file grammar_ttl.c.

◆ TTLParseInit()

void TTLParseInit ( void *yypRawParser TTLParseCTX_PDECL)

Definition at line 498 of file grammar_ttl.c.

◆ TTLParseAlloc()

void * TTLParseAlloc ( void *(* mallocProc )(YYMALLOCARGTYPE) TTLParseCTX_PDECL)

Definition at line 537 of file grammar_ttl.c.

◆ TTLParseFinalize()

void TTLParseFinalize ( void * p)

Definition at line 663 of file grammar_ttl.c.

◆ TTLParseFree()

void TTLParseFree ( void * p,
void(* freeProc )(void *) )

Definition at line 680 of file grammar_ttl.c.

◆ TTLParse()

void TTLParse ( void * yyp,
int yymajor,
TTLParseTOKENTYPE yyminor TTLParseARG_PDECL )

Definition at line 1517 of file grammar_ttl.c.

◆ TTLParseFallback()

int TTLParseFallback ( int iToken)

Definition at line 1734 of file grammar_ttl.c.