Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members   File Members   Related Pages   Examples  

yacc_out_ntriples.cpp

00001 
00002 /*  A Bison parser, made from ntriples.cpp.y
00003     by GNU Bison version 1.28  */
00004 
00005 #define YYBISON 1  /* Identify Bison output.  */
00006 
00007 #define yyparse ntriples_parse
00008 #define yylex ntriples_lex
00009 #define yyerror ntriples_error
00010 #define yylval ntriples_lval
00011 #define yychar ntriples_char
00012 #define yydebug ntriples_debug
00013 #define yynerrs ntriples_nerrs
00014 
00015 #line 1 "ntriples.cpp.y"
00016 
00017 
00018 
00019 static char id[] = "$Id: yacc__out__ntriples_8cpp-source.html,v 1.9 2001/10/10 20:41:00 sandro Exp $";
00020 #include "ntriples.h"
00021 #include "config.h"
00022 #include "NTriplesParser.h"
00023 
00024 extern "C" {
00025 #include <malloc.h>
00026 }
00027 
00028 int ntriples_error(char* message);
00029 int ntriples_lex();
00030     
00031 #include "Symbol.h"
00032 
00033 #define YYSTYPE Symbol
00034 
00035 #ifndef YYSTYPE
00036 #define YYSTYPE int
00037 #endif
00038 #include <stdio.h>
00039 
00040 #ifndef __cplusplus
00041 #ifndef __STDC__
00042 #define const
00043 #endif
00044 #endif
00045 
00046 
00047 
00048 #define YYFINAL     179
00049 #define YYFLAG      -32768
00050 #define YYNTBASE    103
00051 
00052 #define YYTRANSLATE(x) ((unsigned)(x) <= 338 ? yytranslate[x] : 132)
00053 
00054 static const char yytranslate[] = {     0,
00055      2,     2,     2,     2,     2,     2,     2,     2,     2,     5,
00056      2,     2,     6,     2,     2,     2,     2,     2,     2,     2,
00057      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00058      2,     4,     2,     9,    18,     2,     2,     2,     2,     2,
00059      2,     2,     2,     2,     2,     3,     2,     2,     2,     2,
00060      2,     2,     2,     2,     2,     2,     2,    20,     2,     7,
00061      2,     8,     2,     2,     2,     2,     2,     2,     2,     2,
00062      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00063      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00064     12,    10,    13,    17,    19,    11,     2,     2,     2,     2,
00065      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00066      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00067      2,     2,    14,    16,    15,     2,     2,     2,     2,     2,
00068      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00069      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00070      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00071      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00072      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00073      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00074      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00075      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00076      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00077      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00078      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00079      2,     2,     2,     2,     2,     2,     2,     2,     2,     2,
00080      2,     2,     2,     2,     2,     1,    21,    22,    23,    24,
00081     25,    26,    27,    28,    29,    30,    31,    32,    33,    34,
00082     35,    36,    37,    38,    39,    40,    41,    42,    43,    44,
00083     45,    46,    47,    48,    49,    50,    51,    52,    53,    54,
00084     55,    56,    57,    58,    59,    60,    61,    62,    63,    64,
00085     65,    66,    67,    68,    69,    70,    71,    72,    73,    74,
00086     75,    76,    77,    78,    79,    80,    81,    82,    83,    84,
00087     85,    86,    87,    88,    89,    90,    91,    92,    93,    94,
00088     95,    96,    97,    98,    99,   100,   101,   102
00089 };
00090 
00091 #if YYDEBUG != 0
00092 static const short yyprhs[] = {     0,
00093      0,     1,     4,    15,    26,    27,    30,    32,    35,    37,
00094     39,    43,    47,    51,    52,    56,    60,    63,    65,    67,
00095     69,    71,    73,    75,    77,    79,    81,    83,    85,    89,
00096     93,    95,    99,   102,   103,   106,   108,   110,   112,   114,
00097    116,   118,   119,   122,   124,   126,   128,   130,   132,   134,
00098    136,   138,   140,   142,   144,   146,   148,   150,   152,   154,
00099    156,   158,   160,   162,   164,   166,   168,   170,   174,   176,
00100    178,   180,   182,   184,   186,   188,   190,   192,   194,   196,
00101    198,   200,   202,   204,   206,   208,   210,   212,   214,   216,
00102    218,   220,   222,   224,   226,   228,   230,   232,   234,   236,
00103    238,   240,   242,   244,   246,   248,   250,   252,   254,   256,
00104    258,   260,   262,   264,   266,   268,   270,   272,   274,   276,
00105    278,   280,   282,   284,   286,   288,   290,   292,   294,   296,
00106    298,   300,   302,   304,   306,   308,   310,   312,   314,   316,
00107    318,   320,   322,   324,   326,   328,   330
00108 };
00109 
00110 static const short yyrhs[] = {    -1,
00111    104,   103,     0,   105,   108,   106,   108,   106,   108,   105,
00112      3,   105,   107,     0,   105,   108,   106,   108,   106,   109,
00113    105,     3,   105,   107,     0,     0,     4,   105,     0,     4,
00114      0,     4,   106,     0,     5,     0,     6,     0,     7,   112,
00115      8,     0,     7,   113,     8,     0,     9,   110,     9,     0,
00116      0,    10,     9,   110,     0,    10,    10,   110,     0,   111,
00117    110,     0,   121,     0,    11,     0,    12,     0,    13,     0,
00118     14,     0,    15,     0,    16,     0,     7,     0,     8,     0,
00119     17,     0,   115,     0,   115,    18,   119,     0,    19,    20,
00120    114,     0,   119,     0,   116,    20,   120,     0,   128,   117,
00121      0,     0,   118,   117,     0,   128,     0,   131,     0,    21,
00122      0,    22,     0,    23,     0,   120,     0,     0,   121,   120,
00123      0,   122,     0,   123,     0,   125,     0,    24,     0,    25,
00124      0,    26,     0,    27,     0,    28,     0,    29,     0,    30,
00125      0,    21,     0,    31,     0,    32,     0,   127,     0,   124,
00126      0,    22,     0,    33,     0,    23,     0,    34,     0,    35,
00127      0,    36,     0,    37,     0,    38,     0,    39,     0,    40,
00128    126,   126,     0,   131,     0,    41,     0,    42,     0,    43,
00129      0,    44,     0,    45,     0,    46,     0,    47,     0,    48,
00130      0,    49,     0,    50,     0,    51,     0,    52,     0,   128,
00131      0,   131,     0,   129,     0,   130,     0,    47,     0,    48,
00132      0,    49,     0,    50,     0,    51,     0,    52,     0,    53,
00133      0,    54,     0,    55,     0,    56,     0,    57,     0,    58,
00134      0,    59,     0,    60,     0,    61,     0,    62,     0,    63,
00135      0,    64,     0,    65,     0,    66,     0,    67,     0,    68,
00136      0,    69,     0,    70,     0,    71,     0,    72,     0,    41,
00137      0,    42,     0,    43,     0,    44,     0,    45,     0,    46,
00138      0,    73,     0,    74,     0,    75,     0,    76,     0,    77,
00139      0,    78,     0,    79,     0,    80,     0,    81,     0,    82,
00140      0,    83,     0,    84,     0,    85,     0,    86,     0,    87,
00141      0,    88,     0,    89,     0,    90,     0,    91,     0,    92,
00142      0,    93,     0,    94,     0,    95,     0,    96,     0,    97,
00143      0,    98,     0,    99,     0,   100,     0,   101,     0,   102,
00144      0
00145 };
00146 
00147 #endif
00148 
00149 #if YYDEBUG != 0
00150 static const short yyrline[] = { 0,
00151     25,    26,    29,    33,    39,    40,    43,    44,    47,    48,
00152     53,    54,    57,    60,    62,    63,    64,    67,    68,    68,
00153     68,    68,    68,    68,    68,    68,    68,    71,    72,    75,
00154     77,    83,    86,    89,    90,    93,    93,    93,    93,    93,
00155     97,   100,   101,   108,   108,   108,   109,   109,   109,   109,
00156    109,   109,   109,   109,   109,   110,   111,   111,   112,   112,
00157    112,   112,   112,   112,   112,   112,   113,   115,   116,   116,
00158    116,   116,   116,   116,   116,   116,   117,   117,   117,   117,
00159    117,   119,   119,   120,   120,   122,   122,   122,   122,   122,
00160    122,   122,   122,   122,   122,   123,   123,   123,   123,   123,
00161    123,   123,   123,   123,   124,   124,   124,   124,   124,   124,
00162    124,   125,   125,   125,   125,   125,   125,   125,   125,   125,
00163    125,   126,   126,   126,   126,   126,   126,   126,   126,   126,
00164    127,   127,   127,   127,   127,   127,   127,   128,   128,   128,
00165    128,   128,   128,   128,   128,   128,   129
00166 };
00167 #endif
00168 
00169 
00170 #if YYDEBUG != 0 || defined (YYERROR_VERBOSE)
00171 
00172 static const char * const yytname[] = {   "$","error","$undefined.","'.'","' '",
00173 "'\\n'","'\\r'","'<'","'>'","'\\\"'","'\\\\'","'`'","'['","']'","'{'","'}'",
00174 "'|'","'^'","'#'","'_'","':'","\"+\"","\"-\"","\".\"","\";\"","\"/\"","\"?\"",
00175 "\":\"","\"@\"","\"&\"","\"=\"","\"$\"","\",\"","\"_\"","\"!\"","\"~\"","\"*\"",
00176 "\"\\'\"","\"(\"","\")\"","\"%\"","\"A\"","\"B\"","\"C\"","\"D\"","\"E\"","\"F\"",
00177 "\"a\"","\"b\"","\"c\"","\"d\"","\"e\"","\"f\"","\"g\"","\"h\"","\"i\"","\"j\"",
00178 "\"k\"","\"l\"","\"m\"","\"n\"","\"o\"","\"p\"","\"q\"","\"r\"","\"s\"","\"t\"",
00179 "\"u\"","\"v\"","\"w\"","\"x\"","\"y\"","\"z\"","\"G\"","\"H\"","\"I\"","\"J\"",
00180 "\"K\"","\"L\"","\"M\"","\"N\"","\"O\"","\"P\"","\"Q\"","\"R\"","\"S\"","\"T\"",
00181 "\"U\"","\"V\"","\"W\"","\"X\"","\"Y\"","\"Z\"","\"0\"","\"1\"","\"2\"","\"3\"",
00182 "\"4\"","\"5\"","\"6\"","\"7\"","\"8\"","\"9\"","document","statement","ows",
00183 "ws","nl","ident","string_literal","string_contents","notDoubleQuote","absoluteURI_reference",
00184 "existential_term","exi_fragment","absoluteURI","scheme","scheme2","schemeChar",
00185 "fragment","urichars","uric","reserved","unreserved","mark","escaped","hex",
00186 "alphanum","alpha","lowalpha","upalpha","digit", NULL
00187 };
00188 #endif
00189 
00190 static const short yyr1[] = {     0,
00191    103,   103,   104,   104,   105,   105,   106,   106,   107,   107,
00192    108,   108,   109,   110,   110,   110,   110,   111,   111,   111,
00193    111,   111,   111,   111,   111,   111,   111,   112,   112,   113,
00194    114,   115,   116,   117,   117,   118,   118,   118,   118,   118,
00195    119,   120,   120,   121,   121,   121,   122,   122,   122,   122,
00196    122,   122,   122,   122,   122,   122,   123,   123,   124,   124,
00197    124,   124,   124,   124,   124,   124,   124,   125,   126,   126,
00198    126,   126,   126,   126,   126,   126,   126,   126,   126,   126,
00199    126,   127,   127,   128,   128,   129,   129,   129,   129,   129,
00200    129,   129,   129,   129,   129,   129,   129,   129,   129,   129,
00201    129,   129,   129,   129,   129,   129,   129,   129,   129,   129,
00202    129,   130,   130,   130,   130,   130,   130,   130,   130,   130,
00203    130,   130,   130,   130,   130,   130,   130,   130,   130,   130,
00204    130,   130,   130,   130,   130,   130,   130,   131,   131,   131,
00205    131,   131,   131,   131,   131,   131,   131
00206 };
00207 
00208 static const short yyr2[] = {     0,
00209      0,     2,    10,    10,     0,     2,     1,     2,     1,     1,
00210      3,     3,     3,     0,     3,     3,     2,     1,     1,     1,
00211      1,     1,     1,     1,     1,     1,     1,     1,     3,     3,
00212      1,     3,     2,     0,     2,     1,     1,     1,     1,     1,
00213      1,     0,     2,     1,     1,     1,     1,     1,     1,     1,
00214      1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
00215      1,     1,     1,     1,     1,     1,     1,     3,     1,     1,
00216      1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
00217      1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
00218      1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
00219      1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
00220      1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
00221      1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
00222      1,     1,     1,     1,     1,     1,     1,     1,     1,     1,
00223      1,     1,     1,     1,     1,     1,     1
00224 };
00225 
00226 static const short yydefact[] = {     1,
00227      5,     1,     0,     6,     2,     0,     0,     0,   112,   113,
00228    114,   115,   116,   117,    86,    87,    88,    89,    90,    91,
00229     92,    93,    94,    95,    96,    97,    98,    99,   100,   101,
00230    102,   103,   104,   105,   106,   107,   108,   109,   110,   111,
00231    118,   119,   120,   121,   122,   123,   124,   125,   126,   127,
00232    128,   129,   130,   131,   132,   133,   134,   135,   136,   137,
00233      0,     0,    28,     0,    34,    84,    85,     7,     0,    42,
00234     11,    12,    42,    42,    38,    39,    40,   138,   139,   140,
00235    141,   142,   143,   144,   145,   146,   147,    33,    34,    36,
00236     37,     8,     0,    54,    59,    61,    47,    48,    49,    50,
00237     51,    52,    53,    55,    56,    60,    62,    63,    64,    65,
00238     66,    67,     0,    30,    31,    41,    42,    44,    45,    58,
00239     46,    57,    82,    83,    29,    32,    35,     0,    70,    71,
00240     72,    73,    74,    75,    76,    77,    78,    79,    80,    81,
00241      0,    69,    43,    14,     5,     5,    68,    25,    26,     0,
00242     19,    20,    21,    22,    23,    24,    27,     0,    14,    18,
00243      0,     0,    14,    14,    13,    17,     5,     5,    15,    16,
00244      0,     0,     9,    10,     3,     4,     0,     0,     0
00245 };
00246 
00247 static const short yydefgoto[] = {     5,
00248      2,     3,    69,   175,     7,   146,   158,   159,    61,    62,
00249    114,    63,    64,    88,    89,   115,   116,   117,   118,   119,
00250    120,   121,   141,   122,   123,    66,    67,   124
00251 };
00252 
00253 static const short yypact[] = {   102,
00254      9,   102,    -4,-32768,-32768,   326,   108,    93,-32768,-32768,
00255 -32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
00256 -32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
00257 -32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
00258 -32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
00259 -32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
00260    106,   107,    99,    98,   242,-32768,-32768,   108,    -4,   160,
00261 -32768,-32768,   160,   160,-32768,-32768,-32768,-32768,-32768,-32768,
00262 -32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,   242,-32768,
00263 -32768,-32768,   108,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
00264 -32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
00265 -32768,-32768,   378,-32768,-32768,-32768,   160,-32768,-32768,-32768,
00266 -32768,-32768,-32768,-32768,-32768,-32768,-32768,     5,-32768,-32768,
00267 -32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
00268    378,-32768,-32768,    -6,     9,     9,-32768,-32768,-32768,    95,
00269 -32768,-32768,-32768,-32768,-32768,-32768,-32768,   110,    -6,-32768,
00270    120,   121,    -6,    -6,-32768,-32768,     9,     9,-32768,-32768,
00271    105,   105,-32768,-32768,-32768,-32768,   125,   126,-32768
00272 };
00273 
00274 static const short yypgoto[] = {   128,
00275 -32768,    -1,    34,   -42,    30,-32768,   -56,-32768,-32768,-32768,
00276 -32768,-32768,-32768,    40,-32768,    58,    26,   -43,-32768,-32768,
00277 -32768,-32768,    -9,-32768,    91,-32768,-32768,    33
00278 };
00279 
00280 
00281 #define YYLAST      480
00282 
00283 
00284 static const short yytable[] = {     4,
00285    148,   149,     6,   150,   151,   152,   153,   154,   155,   156,
00286    157,     6,     1,   144,    94,    95,    96,    97,    98,    99,
00287    100,   101,   102,   103,   104,   105,   106,   107,   108,   109,
00288    110,   111,   112,   113,     9,    10,    11,    12,    13,    14,
00289     15,    16,    17,    18,    19,    20,    21,    22,    23,    24,
00290     25,    26,    27,    28,    29,    30,    31,    32,    33,    34,
00291     35,    36,    37,    38,    39,    40,    41,    42,    43,    44,
00292     45,    46,    47,    48,    49,    50,    51,    52,    53,    54,
00293     55,    56,    57,    58,    59,    60,    78,    79,    80,    81,
00294     82,    83,    84,    85,    86,    87,    65,    91,    93,   126,
00295    160,    92,   166,   163,   164,     1,   169,   170,    -5,   173,
00296    174,    68,    70,    71,    72,   160,    73,    74,   165,   160,
00297    160,    91,   167,   168,   178,   179,   128,   177,   127,   176,
00298    125,   147,     0,     0,     0,     0,     0,     0,     0,     0,
00299      0,     0,   143,   161,   162,   142,     0,     0,     0,     0,
00300      0,     0,     0,     0,     0,    90,     0,   145,     0,     0,
00301      0,     0,     0,     0,     0,   171,   172,     0,     0,     0,
00302      0,     0,     0,   142,     0,     0,     0,     0,     0,    90,
00303     94,    95,    96,    97,    98,    99,   100,   101,   102,   103,
00304    104,   105,   106,   107,   108,   109,   110,   111,   112,   113,
00305      9,    10,    11,    12,    13,    14,    15,    16,    17,    18,
00306     19,    20,    21,    22,    23,    24,    25,    26,    27,    28,
00307     29,    30,    31,    32,    33,    34,    35,    36,    37,    38,
00308     39,    40,    41,    42,    43,    44,    45,    46,    47,    48,
00309     49,    50,    51,    52,    53,    54,    55,    56,    57,    58,
00310     59,    60,    78,    79,    80,    81,    82,    83,    84,    85,
00311     86,    87,    75,    76,    77,     0,     0,     0,     0,     0,
00312      0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
00313      0,     0,     9,    10,    11,    12,    13,    14,    15,    16,
00314     17,    18,    19,    20,    21,    22,    23,    24,    25,    26,
00315     27,    28,    29,    30,    31,    32,    33,    34,    35,    36,
00316     37,    38,    39,    40,    41,    42,    43,    44,    45,    46,
00317     47,    48,    49,    50,    51,    52,    53,    54,    55,    56,
00318     57,    58,    59,    60,    78,    79,    80,    81,    82,    83,
00319     84,    85,    86,    87,     8,     0,     0,     0,     0,     0,
00320      0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
00321      0,     0,     0,     0,     0,     0,     9,    10,    11,    12,
00322     13,    14,    15,    16,    17,    18,    19,    20,    21,    22,
00323     23,    24,    25,    26,    27,    28,    29,    30,    31,    32,
00324     33,    34,    35,    36,    37,    38,    39,    40,    41,    42,
00325     43,    44,    45,    46,    47,    48,    49,    50,    51,    52,
00326     53,    54,    55,    56,    57,    58,    59,    60,   129,   130,
00327    131,   132,   133,   134,   135,   136,   137,   138,   139,   140,
00328      0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
00329      0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
00330      0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
00331      0,     0,     0,     0,     0,     0,     0,     0,     0,     0,
00332     78,    79,    80,    81,    82,    83,    84,    85,    86,    87
00333 };
00334 
00335 static const short yycheck[] = {     1,
00336      7,     8,     7,    10,    11,    12,    13,    14,    15,    16,
00337     17,     7,     4,     9,    21,    22,    23,    24,    25,    26,
00338     27,    28,    29,    30,    31,    32,    33,    34,    35,    36,
00339     37,    38,    39,    40,    41,    42,    43,    44,    45,    46,
00340     47,    48,    49,    50,    51,    52,    53,    54,    55,    56,
00341     57,    58,    59,    60,    61,    62,    63,    64,    65,    66,
00342     67,    68,    69,    70,    71,    72,    73,    74,    75,    76,
00343     77,    78,    79,    80,    81,    82,    83,    84,    85,    86,
00344     87,    88,    89,    90,    91,    92,    93,    94,    95,    96,
00345     97,    98,    99,   100,   101,   102,     6,    65,    69,    74,
00346    144,    68,   159,     9,    10,     4,   163,   164,     7,     5,
00347      6,     4,    20,     8,     8,   159,    18,    20,     9,   163,
00348    164,    89,     3,     3,     0,     0,    93,     0,    89,   172,
00349     73,   141,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
00350     -1,    -1,   117,   145,   146,   113,    -1,    -1,    -1,    -1,
00351     -1,    -1,    -1,    -1,    -1,    65,    -1,   128,    -1,    -1,
00352     -1,    -1,    -1,    -1,    -1,   167,   168,    -1,    -1,    -1,
00353     -1,    -1,    -1,   141,    -1,    -1,    -1,    -1,    -1,    89,
00354     21,    22,    23,    24,    25,    26,    27,    28,    29,    30,
00355     31,    32,    33,    34,    35,    36,    37,    38,    39,    40,
00356     41,    42,    43,    44,    45,    46,    47,    48,    49,    50,
00357     51,    52,    53,    54,    55,    56,    57,    58,    59,    60,
00358     61,    62,    63,    64,    65,    66,    67,    68,    69,    70,
00359     71,    72,    73,    74,    75,    76,    77,    78,    79,    80,
00360     81,    82,    83,    84,    85,    86,    87,    88,    89,    90,
00361     91,    92,    93,    94,    95,    96,    97,    98,    99,   100,
00362    101,   102,    21,    22,    23,    -1,    -1,    -1,    -1,    -1,
00363     -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
00364     -1,    -1,    41,    42,    43,    44,    45,    46,    47,    48,
00365     49,    50,    51,    52,    53,    54,    55,    56,    57,    58,
00366     59,    60,    61,    62,    63,    64,    65,    66,    67,    68,
00367     69,    70,    71,    72,    73,    74,    75,    76,    77,    78,
00368     79,    80,    81,    82,    83,    84,    85,    86,    87,    88,
00369     89,    90,    91,    92,    93,    94,    95,    96,    97,    98,
00370     99,   100,   101,   102,    19,    -1,    -1,    -1,    -1,    -1,
00371     -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
00372     -1,    -1,    -1,    -1,    -1,    -1,    41,    42,    43,    44,
00373     45,    46,    47,    48,    49,    50,    51,    52,    53,    54,
00374     55,    56,    57,    58,    59,    60,    61,    62,    63,    64,
00375     65,    66,    67,    68,    69,    70,    71,    72,    73,    74,
00376     75,    76,    77,    78,    79,    80,    81,    82,    83,    84,
00377     85,    86,    87,    88,    89,    90,    91,    92,    41,    42,
00378     43,    44,    45,    46,    47,    48,    49,    50,    51,    52,
00379     -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
00380     -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
00381     -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
00382     -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,    -1,
00383     93,    94,    95,    96,    97,    98,    99,   100,   101,   102
00384 };
00385 /* -*-C-*-  Note some compilers choke on comments on `#line' lines.  */
00386 #line 3 "/usr/share/misc/bison.simple"
00387 /* This file comes from bison-1.28.  */
00388 
00389 /* Skeleton output parser for bison,
00390    Copyright (C) 1984, 1989, 1990 Free Software Foundation, Inc.
00391 
00392    This program is free software; you can redistribute it and/or modify
00393    it under the terms of the GNU General Public License as published by
00394    the Free Software Foundation; either version 2, or (at your option)
00395    any later version.
00396 
00397    This program is distributed in the hope that it will be useful,
00398    but WITHOUT ANY WARRANTY; without even the implied warranty of
00399    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00400    GNU General Public License for more details.
00401 
00402    You should have received a copy of the GNU General Public License
00403    along with this program; if not, write to the Free Software
00404    Foundation, Inc., 59 Temple Place - Suite 330,
00405    Boston, MA 02111-1307, USA.  */
00406 
00407 /* As a special exception, when this file is copied by Bison into a
00408    Bison output file, you may use that output file without restriction.
00409    This special exception was added by the Free Software Foundation
00410    in version 1.24 of Bison.  */
00411 
00412 /* This is the parser code that is written into each bison parser
00413   when the %semantic_parser declaration is not specified in the grammar.
00414   It was written by Richard Stallman by simplifying the hairy parser
00415   used when %semantic_parser is specified.  */
00416 
00417 #ifndef YYSTACK_USE_ALLOCA
00418 #ifdef alloca
00419 #define YYSTACK_USE_ALLOCA
00420 #else /* alloca not defined */
00421 #ifdef __GNUC__
00422 #define YYSTACK_USE_ALLOCA
00423 #define alloca __builtin_alloca
00424 #else /* not GNU C.  */
00425 #if (!defined (__STDC__) && defined (sparc)) || defined (__sparc__) || defined (__sparc) || defined (__sgi) || (defined (__sun) && defined (__i386))
00426 #define YYSTACK_USE_ALLOCA
00427 #include <alloca.h>
00428 #else /* not sparc */
00429 /* We think this test detects Watcom and Microsoft C.  */
00430 /* This used to test MSDOS, but that is a bad idea
00431    since that symbol is in the user namespace.  */
00432 #if (defined (_MSDOS) || defined (_MSDOS_)) && !defined (__TURBOC__)
00433 #if 0 /* No need for malloc.h, which pollutes the namespace;
00434      instead, just don't use alloca.  */
00435 #include <malloc.h>
00436 #endif
00437 #else /* not MSDOS, or __TURBOC__ */
00438 #if defined(_AIX)
00439 /* I don't know what this was needed for, but it pollutes the namespace.
00440    So I turned it off.   rms, 2 May 1997.  */
00441 /* #include <malloc.h>  */
00442  #pragma alloca
00443 #define YYSTACK_USE_ALLOCA
00444 #else /* not MSDOS, or __TURBOC__, or _AIX */
00445 #if 0
00446 #ifdef __hpux /* haible@ilog.fr says this works for HPUX 9.05 and up,
00447          and on HPUX 10.  Eventually we can turn this on.  */
00448 #define YYSTACK_USE_ALLOCA
00449 #define alloca __builtin_alloca
00450 #endif /* __hpux */
00451 #endif
00452 #endif /* not _AIX */
00453 #endif /* not MSDOS, or __TURBOC__ */
00454 #endif /* not sparc */
00455 #endif /* not GNU C */
00456 #endif /* alloca not defined */
00457 #endif /* YYSTACK_USE_ALLOCA not defined */
00458 
00459 #ifdef YYSTACK_USE_ALLOCA
00460 #define YYSTACK_ALLOC alloca
00461 #else
00462 #define YYSTACK_ALLOC malloc
00463 #endif
00464 
00465 /* Note: there must be only one dollar sign in this file.
00466    It is replaced by the list of actions, each action
00467    as one case of the switch.  */
00468 
00469 #define yyerrok     (yyerrstatus = 0)
00470 #define yyclearin   (yychar = YYEMPTY)
00471 #define YYEMPTY     -2
00472 #define YYEOF       0
00473 #define YYACCEPT    goto yyacceptlab
00474 #define YYABORT     goto yyabortlab
00475 #define YYERROR     goto yyerrlab1
00476 /* Like YYERROR except do call yyerror.
00477    This remains here temporarily to ease the
00478    transition to the new meaning of YYERROR, for GCC.
00479    Once GCC version 2 has supplanted version 1, this can go.  */
00480 #define YYFAIL      goto yyerrlab
00481 #define YYRECOVERING()  (!!yyerrstatus)
00482 #define YYBACKUP(token, value) \
00483 do                              \
00484   if (yychar == YYEMPTY && yylen == 1)              \
00485     { yychar = (token), yylval = (value);           \
00486       yychar1 = YYTRANSLATE (yychar);               \
00487       YYPOPSTACK;                       \
00488       goto yybackup;                        \
00489     }                               \
00490   else                              \
00491     { yyerror ("syntax error: cannot back up"); YYERROR; }  \
00492 while (0)
00493 
00494 #define YYTERROR    1
00495 #define YYERRCODE   256
00496 
00497 #ifndef YYPURE
00498 #define YYLEX       yylex()
00499 #endif
00500 
00501 #ifdef YYPURE
00502 #ifdef YYLSP_NEEDED
00503 #ifdef YYLEX_PARAM
00504 #define YYLEX       yylex(&yylval, &yylloc, YYLEX_PARAM)
00505 #else
00506 #define YYLEX       yylex(&yylval, &yylloc)
00507 #endif
00508 #else /* not YYLSP_NEEDED */
00509 #ifdef YYLEX_PARAM
00510 #define YYLEX       yylex(&yylval, YYLEX_PARAM)
00511 #else
00512 #define YYLEX       yylex(&yylval)
00513 #endif
00514 #endif /* not YYLSP_NEEDED */
00515 #endif
00516 
00517 /* If nonreentrant, generate the variables here */
00518 
00519 #ifndef YYPURE
00520 
00521 int yychar;         /*  the lookahead symbol        */
00522 YYSTYPE yylval;         /*  the semantic value of the       */
00523                 /*  lookahead symbol            */
00524 
00525 #ifdef YYLSP_NEEDED
00526 YYLTYPE yylloc;         /*  location data for the lookahead */
00527                 /*  symbol              */
00528 #endif
00529 
00530 int yynerrs;            /*  number of parse errors so far       */
00531 #endif  /* not YYPURE */
00532 
00533 #if YYDEBUG != 0
00534 int yydebug;            /*  nonzero means print parse trace */
00535 /* Since this is uninitialized, it does not stop multiple parsers
00536    from coexisting.  */
00537 #endif
00538 
00539 /*  YYINITDEPTH indicates the initial size of the parser's stacks   */
00540 
00541 #ifndef YYINITDEPTH
00542 #define YYINITDEPTH 200
00543 #endif
00544 
00545 /*  YYMAXDEPTH is the maximum size the stacks can grow to
00546     (effective only if the built-in stack extension method is used).  */
00547 
00548 #if YYMAXDEPTH == 0
00549 #undef YYMAXDEPTH
00550 #endif
00551 
00552 #ifndef YYMAXDEPTH
00553 #define YYMAXDEPTH 10000
00554 #endif
00555 
00556 /* Define __yy_memcpy.  Note that the size argument
00557    should be passed with type unsigned int, because that is what the non-GCC
00558    definitions require.  With GCC, __builtin_memcpy takes an arg
00559    of type size_t, but it can handle unsigned int.  */
00560 
00561 #if __GNUC__ > 1        /* GNU C and GNU C++ define this.  */
00562 #define __yy_memcpy(TO,FROM,COUNT)  __builtin_memcpy(TO,FROM,COUNT)
00563 #else               /* not GNU C or C++ */
00564 #ifndef __cplusplus
00565 
00566 /* This is the most reliable way to avoid incompatibilities
00567    in available built-in functions on various systems.  */
00568 static void
00569 __yy_memcpy (to, from, count)
00570      char *to;
00571      char *from;
00572      unsigned int count;
00573 {
00574   register char *f = from;
00575   register char *t = to;
00576   register int i = count;
00577 
00578   while (i-- > 0)
00579     *t++ = *f++;
00580 }
00581 
00582 #else /* __cplusplus */
00583 
00584 /* This is the most reliable way to avoid incompatibilities
00585    in available built-in functions on various systems.  */
00586 static void
00587 __yy_memcpy (char *to, char *from, unsigned int count)
00588 {
00589   register char *t = to;
00590   register char *f = from;
00591   register int i = count;
00592 
00593   while (i-- > 0)
00594     *t++ = *f++;
00595 }
00596 
00597 #endif
00598 #endif
00599 
00600 #line 217 "/usr/share/misc/bison.simple"
00601 
00602 /* The user can define YYPARSE_PARAM as the name of an argument to be passed
00603    into yyparse.  The argument should have type void *.
00604    It should actually point to an object.
00605    Grammar actions can access the variable by casting it
00606    to the proper pointer type.  */
00607 
00608 #ifdef YYPARSE_PARAM
00609 #ifdef __cplusplus
00610 #define YYPARSE_PARAM_ARG void *YYPARSE_PARAM
00611 #define YYPARSE_PARAM_DECL
00612 #else /* not __cplusplus */
00613 #define YYPARSE_PARAM_ARG YYPARSE_PARAM
00614 #define YYPARSE_PARAM_DECL void *YYPARSE_PARAM;
00615 #endif /* not __cplusplus */
00616 #else /* not YYPARSE_PARAM */
00617 #define YYPARSE_PARAM_ARG
00618 #define YYPARSE_PARAM_DECL
00619 #endif /* not YYPARSE_PARAM */
00620 
00621 /* Prevent warning if -Wstrict-prototypes.  */
00622 #ifdef __GNUC__
00623 #ifdef YYPARSE_PARAM
00624 int yyparse (void *);
00625 #else
00626 int yyparse (void);
00627 #endif
00628 #endif
00629 
00630 int
00631 yyparse(YYPARSE_PARAM_ARG)
00632      YYPARSE_PARAM_DECL
00633 {
00634   register int yystate;
00635   register int yyn;
00636   register short *yyssp;
00637   register YYSTYPE *yyvsp;
00638   int yyerrstatus;  /*  number of tokens to shift before error messages enabled */
00639   int yychar1 = 0;      /*  lookahead token as an internal (translated) token number */
00640 
00641   short yyssa[YYINITDEPTH]; /*  the state stack         */
00642   YYSTYPE yyvsa[YYINITDEPTH];   /*  the semantic value stack        */
00643 
00644   short *yyss = yyssa;      /*  refer to the stacks thru separate pointers */
00645   YYSTYPE *yyvs = yyvsa;    /*  to allow yyoverflow to reallocate them elsewhere */
00646 
00647 #ifdef YYLSP_NEEDED
00648   YYLTYPE yylsa[YYINITDEPTH];   /*  the location stack          */
00649   YYLTYPE *yyls = yylsa;
00650   YYLTYPE *yylsp;
00651 
00652 #define YYPOPSTACK   (yyvsp--, yyssp--, yylsp--)
00653 #else
00654 #define YYPOPSTACK   (yyvsp--, yyssp--)
00655 #endif
00656 
00657   int yystacksize = YYINITDEPTH;
00658   int yyfree_stacks = 0;
00659 
00660 #ifdef YYPURE
00661   int yychar;
00662   YYSTYPE yylval;
00663   int yynerrs;
00664 #ifdef YYLSP_NEEDED
00665   YYLTYPE yylloc;
00666 #endif
00667 #endif
00668 
00669   YYSTYPE yyval;        /*  the variable used to return     */
00670                 /*  semantic values from the action */
00671                 /*  routines                */
00672 
00673   int yylen;
00674 
00675 #if YYDEBUG != 0
00676   if (yydebug)
00677     fprintf(stderr, "Starting parse\n");
00678 #endif
00679 
00680   yystate = 0;
00681   yyerrstatus = 0;
00682   yynerrs = 0;
00683   yychar = YYEMPTY;     /* Cause a token to be read.  */
00684 
00685   /* Initialize stack pointers.
00686      Waste one element of value and location stack
00687      so that they stay on the same level as the state stack.
00688      The wasted elements are never initialized.  */
00689 
00690   yyssp = yyss - 1;
00691   yyvsp = yyvs;
00692 #ifdef YYLSP_NEEDED
00693   yylsp = yyls;
00694 #endif
00695 
00696 /* Push a new state, which is found in  yystate  .  */
00697 /* In all cases, when you get here, the value and location stacks
00698    have just been pushed. so pushing a state here evens the stacks.  */
00699 yynewstate:
00700 
00701   *++yyssp = yystate;
00702 
00703   if (yyssp >= yyss + yystacksize - 1)
00704     {
00705       /* Give user a chance to reallocate the stack */
00706       /* Use copies of these so that the &'s don't force the real ones into memory. */
00707       YYSTYPE *yyvs1 = yyvs;
00708       short *yyss1 = yyss;
00709 #ifdef YYLSP_NEEDED
00710       YYLTYPE *yyls1 = yyls;
00711 #endif
00712 
00713       /* Get the current used size of the three stacks, in elements.  */
00714       int size = yyssp - yyss + 1;
00715 
00716 #ifdef yyoverflow
00717       /* Each stack pointer address is followed by the size of
00718      the data in use in that stack, in bytes.  */
00719 #ifdef YYLSP_NEEDED
00720       /* This used to be a conditional around just the two extra args,
00721      but that might be undefined if yyoverflow is a macro.  */
00722       yyoverflow("parser stack overflow",
00723          &yyss1, size * sizeof (*yyssp),
00724          &yyvs1, size * sizeof (*yyvsp),
00725          &yyls1, size * sizeof (*yylsp),
00726          &yystacksize);
00727 #else
00728       yyoverflow("parser stack overflow",
00729          &yyss1, size * sizeof (*yyssp),
00730          &yyvs1, size * sizeof (*yyvsp),
00731          &yystacksize);
00732 #endif
00733 
00734       yyss = yyss1; yyvs = yyvs1;
00735 #ifdef YYLSP_NEEDED
00736       yyls = yyls1;
00737 #endif
00738 #else /* no yyoverflow */
00739       /* Extend the stack our own way.  */
00740       if (yystacksize >= YYMAXDEPTH)
00741     {
00742       yyerror("parser stack overflow");
00743       if (yyfree_stacks)
00744         {
00745           free (yyss);
00746           free (yyvs);
00747 #ifdef YYLSP_NEEDED
00748           free (yyls);
00749 #endif
00750         }
00751       return 2;
00752     }
00753       yystacksize *= 2;
00754       if (yystacksize > YYMAXDEPTH)
00755     yystacksize = YYMAXDEPTH;
00756 #ifndef YYSTACK_USE_ALLOCA
00757       yyfree_stacks = 1;
00758 #endif
00759       yyss = (short *) YYSTACK_ALLOC (yystacksize * sizeof (*yyssp));
00760       __yy_memcpy ((char *)yyss, (char *)yyss1,
00761            size * (unsigned int) sizeof (*yyssp));
00762       yyvs = (YYSTYPE *) YYSTACK_ALLOC (yystacksize * sizeof (*yyvsp));
00763       __yy_memcpy ((char *)yyvs, (char *)yyvs1,
00764            size * (unsigned int) sizeof (*yyvsp));
00765 #ifdef YYLSP_NEEDED
00766       yyls = (YYLTYPE *) YYSTACK_ALLOC (yystacksize * sizeof (*yylsp));
00767       __yy_memcpy ((char *)yyls, (char *)yyls1,
00768            size * (unsigned int) sizeof (*yylsp));
00769 #endif
00770 #endif /* no yyoverflow */
00771 
00772       yyssp = yyss + size - 1;
00773       yyvsp = yyvs + size - 1;
00774 #ifdef YYLSP_NEEDED
00775       yylsp = yyls + size - 1;
00776 #endif
00777 
00778 #if YYDEBUG != 0
00779       if (yydebug)
00780     fprintf(stderr, "Stack size increased to %d\n", yystacksize);
00781 #endif
00782 
00783       if (yyssp >= yyss + yystacksize - 1)
00784     YYABORT;
00785     }
00786 
00787 #if YYDEBUG != 0
00788   if (yydebug)
00789     fprintf(stderr, "Entering state %d\n", yystate);
00790 #endif
00791 
00792   goto yybackup;
00793  yybackup:
00794 
00795 /* Do appropriate processing given the current state.  */
00796 /* Read a lookahead token if we need one and don't already have one.  */
00797 /* yyresume: */
00798 
00799   /* First try to decide what to do without reference to lookahead token.  */
00800 
00801   yyn = yypact[yystate];
00802   if (yyn == YYFLAG)
00803     goto yydefault;
00804 
00805   /* Not known => get a lookahead token if don't already have one.  */
00806 
00807   /* yychar is either YYEMPTY or YYEOF
00808      or a valid token in external form.  */
00809 
00810   if (yychar == YYEMPTY)
00811     {
00812 #if YYDEBUG != 0
00813       if (yydebug)
00814     fprintf(stderr, "Reading a token: ");
00815 #endif
00816       yychar = YYLEX;
00817     }
00818 
00819   /* Convert token to internal form (in yychar1) for indexing tables with */
00820 
00821   if (yychar <= 0)      /* This means end of input. */
00822     {
00823       yychar1 = 0;
00824       yychar = YYEOF;       /* Don't call YYLEX any more */
00825 
00826 #if YYDEBUG != 0
00827       if (yydebug)
00828     fprintf(stderr, "Now at end of input.\n");
00829 #endif
00830     }
00831   else
00832     {
00833       yychar1 = YYTRANSLATE(yychar);
00834 
00835 #if YYDEBUG != 0
00836       if (yydebug)
00837     {
00838       fprintf (stderr, "Next token is %d (%s", yychar, yytname[yychar1]);
00839       /* Give the individual parser a way to print the precise meaning
00840          of a token, for further debugging info.  */
00841 #ifdef YYPRINT
00842       YYPRINT (stderr, yychar, yylval);
00843 #endif
00844       fprintf (stderr, ")\n");
00845     }
00846 #endif
00847     }
00848 
00849   yyn += yychar1;
00850   if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar1)
00851     goto yydefault;
00852 
00853   yyn = yytable[yyn];
00854 
00855   /* yyn is what to do for this token type in this state.
00856      Negative => reduce, -yyn is rule number.
00857      Positive => shift, yyn is new state.
00858        New state is final state => don't bother to shift,
00859        just return success.
00860      0, or most negative number => error.  */
00861 
00862   if (yyn < 0)
00863     {
00864       if (yyn == YYFLAG)
00865     goto yyerrlab;
00866       yyn = -yyn;
00867       goto yyreduce;
00868     }
00869   else if (yyn == 0)
00870     goto yyerrlab;
00871 
00872   if (yyn == YYFINAL)
00873     YYACCEPT;
00874 
00875   /* Shift the lookahead token.  */
00876 
00877 #if YYDEBUG != 0
00878   if (yydebug)
00879     fprintf(stderr, "Shifting token %d (%s), ", yychar, yytname[yychar1]);
00880 #endif
00881 
00882   /* Discard the token being shifted unless it is eof.  */
00883   if (yychar != YYEOF)
00884     yychar = YYEMPTY;
00885 
00886   *++yyvsp = yylval;
00887 #ifdef YYLSP_NEEDED
00888   *++yylsp = yylloc;
00889 #endif
00890 
00891   /* count tokens shifted since error; after three, turn off error status.  */
00892   if (yyerrstatus) yyerrstatus--;
00893 
00894   yystate = yyn;
00895   goto yynewstate;
00896 
00897 /* Do the default action for the current state.  */
00898 yydefault:
00899 
00900   yyn = yydefact[yystate];
00901   if (yyn == 0)
00902     goto yyerrlab;
00903 
00904 /* Do a reduction.  yyn is the number of a rule to reduce with.  */
00905 yyreduce:
00906   yylen = yyr2[yyn];
00907   if (yylen > 0)
00908     yyval = yyvsp[1-yylen]; /* implement default value of the action */
00909 
00910 #if YYDEBUG != 0
00911   if (yydebug)
00912     {
00913       int i;
00914 
00915       fprintf (stderr, "Reducing via rule %d (line %d), ",
00916            yyn, yyrline[yyn]);
00917 
00918       /* Print the symbols being reduced, and their result.  */
00919       for (i = yyprhs[yyn]; yyrhs[i] > 0; i++)
00920     fprintf (stderr, "%s ", yytname[yyrhs[i]]);
00921       fprintf (stderr, " -> %s\n", yytname[yyr1[yyn]]);
00922     }
00923 #endif
00924 
00925 
00926   switch (yyn) {
00927 
00928 case 3:
00929 #line 30 "ntriples.cpp.y"
00930 {
00931 //  ntriples_parser->getSink()->add($2, $4, $6);
00932     ;
00933     break;}
00934 case 4:
00935 #line 34 "ntriples.cpp.y"
00936 {
00937 //  ntriples_parser->getSink()->add($2, $4, $6);
00938     ;
00939     break;}
00940 case 31:
00941 #line 78 "ntriples.cpp.y"
00942 { 
00943 //  $$ = Symbol.variable(buf);
00944     ;
00945     break;}
00946 }
00947    /* the action file gets copied in in place of this dollarsign */
00948 #line 543 "/usr/share/misc/bison.simple"
00949 
00950   yyvsp -= yylen;
00951   yyssp -= yylen;
00952 #ifdef YYLSP_NEEDED
00953   yylsp -= yylen;
00954 #endif
00955 
00956 #if YYDEBUG != 0
00957   if (yydebug)
00958     {
00959       short *ssp1 = yyss - 1;
00960       fprintf (stderr, "state stack now");
00961       while (ssp1 != yyssp)
00962     fprintf (stderr, " %d", *++ssp1);
00963       fprintf (stderr, "\n");
00964     }
00965 #endif
00966 
00967   *++yyvsp = yyval;
00968 
00969 #ifdef YYLSP_NEEDED
00970   yylsp++;
00971   if (yylen == 0)
00972     {
00973       yylsp->first_line = yylloc.first_line;
00974       yylsp->first_column = yylloc.first_column;
00975       yylsp->last_line = (yylsp-1)->last_line;
00976       yylsp->last_column = (yylsp-1)->last_column;
00977       yylsp->text = 0;
00978     }
00979   else
00980     {
00981       yylsp->last_line = (yylsp+yylen-1)->last_line;
00982       yylsp->last_column = (yylsp+yylen-1)->last_column;
00983     }
00984 #endif
00985 
00986   /* Now "shift" the result of the reduction.
00987      Determine what state that goes to,
00988      based on the state we popped back to
00989      and the rule number reduced by.  */
00990 
00991   yyn = yyr1[yyn];
00992 
00993   yystate = yypgoto[yyn - YYNTBASE] + *yyssp;
00994   if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp)
00995     yystate = yytable[yystate];
00996   else
00997     yystate = yydefgoto[yyn - YYNTBASE];
00998 
00999   goto yynewstate;
01000 
01001 yyerrlab:   /* here on detecting error */
01002 
01003   if (! yyerrstatus)
01004     /* If not already recovering from an error, report this error.  */
01005     {
01006       ++yynerrs;
01007 
01008 #ifdef YYERROR_VERBOSE
01009       yyn = yypact[yystate];
01010 
01011       if (yyn > YYFLAG && yyn < YYLAST)
01012     {
01013       int size = 0;
01014       char *msg;
01015       int x, count;
01016 
01017       count = 0;
01018       /* Start X at -yyn if nec to avoid negative indexes in yycheck.  */
01019       for (x = (yyn < 0 ? -yyn : 0);
01020            x < (sizeof(yytname) / sizeof(char *)); x++)
01021         if (yycheck[x + yyn] == x)
01022           size += strlen(yytname[x]) + 15, count++;
01023       msg = (char *) malloc(size + 15);
01024       if (msg != 0)
01025         {
01026           strcpy(msg, "parse error");
01027 
01028           if (count < 5)
01029         {
01030           count = 0;
01031           for (x = (yyn < 0 ? -yyn : 0);
01032                x < (sizeof(yytname) / sizeof(char *)); x++)
01033             if (yycheck[x + yyn] == x)
01034               {
01035             strcat(msg, count == 0 ? ", expecting `" : " or `");
01036             strcat(msg, yytname[x]);
01037             strcat(msg, "'");
01038             count++;
01039               }
01040         }
01041           yyerror(msg);
01042           free(msg);
01043         }
01044       else
01045         yyerror ("parse error; also virtual memory exceeded");
01046     }
01047       else
01048 #endif /* YYERROR_VERBOSE */
01049     yyerror("parse error");
01050     }
01051 
01052   goto yyerrlab1;
01053 yyerrlab1:   /* here on error raised explicitly by an action */
01054 
01055   if (yyerrstatus == 3)
01056     {
01057       /* if just tried and failed to reuse lookahead token after an error, discard it.  */
01058 
01059       /* return failure if at end of input */
01060       if (yychar == YYEOF)
01061     YYABORT;
01062 
01063 #if YYDEBUG != 0
01064       if (yydebug)
01065     fprintf(stderr, "Discarding token %d (%s).\n", yychar, yytname[yychar1]);
01066 #endif
01067 
01068       yychar = YYEMPTY;
01069     }
01070 
01071   /* Else will try to reuse lookahead token
01072      after shifting the error token.  */
01073 
01074   yyerrstatus = 3;      /* Each real token shifted decrements this */
01075 
01076   goto yyerrhandle;
01077 
01078 yyerrdefault:  /* current state does not do anything special for the error token. */
01079 
01080 #if 0
01081   /* This is wrong; only states that explicitly want error tokens
01082      should shift them.  */
01083   yyn = yydefact[yystate];  /* If its default is to accept any token, ok.  Otherwise pop it.*/
01084   if (yyn) goto yydefault;
01085 #endif
01086 
01087 yyerrpop:   /* pop the current state because it cannot handle the error token */
01088 
01089   if (yyssp == yyss) YYABORT;
01090   yyvsp--;
01091   yystate = *--yyssp;
01092 #ifdef YYLSP_NEEDED
01093   yylsp--;
01094 #endif
01095 
01096 #if YYDEBUG != 0
01097   if (yydebug)
01098     {
01099       short *ssp1 = yyss - 1;
01100       fprintf (stderr, "Error: state stack now");
01101       while (ssp1 != yyssp)
01102     fprintf (stderr, " %d", *++ssp1);
01103       fprintf (stderr, "\n");
01104     }
01105 #endif
01106 
01107 yyerrhandle:
01108 
01109   yyn = yypact[yystate];
01110   if (yyn == YYFLAG)
01111     goto yyerrdefault;
01112 
01113   yyn += YYTERROR;
01114   if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != YYTERROR)
01115     goto yyerrdefault;
01116 
01117   yyn = yytable[yyn];
01118   if (yyn < 0)
01119     {
01120       if (yyn == YYFLAG)
01121     goto yyerrpop;
01122       yyn = -yyn;
01123       goto yyreduce;
01124     }
01125   else if (yyn == 0)
01126     goto yyerrpop;
01127 
01128   if (yyn == YYFINAL)
01129     YYACCEPT;
01130 
01131 #if YYDEBUG != 0
01132   if (yydebug)
01133     fprintf(stderr, "Shifting error token, ");
01134 #endif
01135 
01136   *++yyvsp = yylval;
01137 #ifdef YYLSP_NEEDED
01138   *++yylsp = yylloc;
01139 #endif
01140 
01141   yystate = yyn;
01142   goto yynewstate;
01143 
01144  yyacceptlab:
01145   /* YYACCEPT comes here.  */
01146   if (yyfree_stacks)
01147     {
01148       free (yyss);
01149       free (yyvs);
01150 #ifdef YYLSP_NEEDED
01151       free (yyls);
01152 #endif
01153     }
01154   return 0;
01155 
01156  yyabortlab:
01157   /* YYABORT comes here.  */
01158   if (yyfree_stacks)
01159     {
01160       free (yyss);
01161       free (yyvs);
01162 #ifdef YYLSP_NEEDED
01163       free (yyls);
01164 #endif
01165     }
01166   return 1;
01167 }
01168 #line 133 "ntriples.cpp.y"
01169 
01170 
01171 int ntriples_error(char* message)
01172 {
01173     std::cerr << message;
01174     return 0;
01175 }
01176 
01177 int ntriples_lex()
01178 {
01179     char c;
01180     int bytes = ntriples_parser->fifo.read(&c, 1);
01181     if (bytes == 0) return 0;
01182     return c;
01183 }
01184     

Home to blindfold. This page generated via doxygen 1.2.11.1 Wed Oct 10 16:40:33 2001.