|
@@ -10,26 +10,39 @@
|
|
|
#define yychar xyychar
|
|
#define yychar xyychar
|
|
|
#define yydebug xyydebug
|
|
#define yydebug xyydebug
|
|
|
#define yynerrs xyynerrs
|
|
#define yynerrs xyynerrs
|
|
|
-# define INTEGER 257
|
|
|
|
|
-# define REAL 258
|
|
|
|
|
-# define STRING 259
|
|
|
|
|
-# define IDENTIFIER 260
|
|
|
|
|
-# define WINDOWS_GUID 261
|
|
|
|
|
-# define KW_ARRAY 262
|
|
|
|
|
-# define KW_BYTE 263
|
|
|
|
|
-# define KW_CHAR 264
|
|
|
|
|
-# define KW_CSTRING 265
|
|
|
|
|
-# define KW_DOUBLE 266
|
|
|
|
|
-# define KW_DWORD 267
|
|
|
|
|
-# define KW_FLOAT 268
|
|
|
|
|
-# define KW_STRING 269
|
|
|
|
|
-# define KW_TEMPLATE 270
|
|
|
|
|
-# define KW_UCHAR 271
|
|
|
|
|
-# define KW_UNICODE 272
|
|
|
|
|
-# define KW_WORD 273
|
|
|
|
|
-# define ELLIPSIS 274
|
|
|
|
|
-
|
|
|
|
|
-#line 6 "xParser.yxx"
|
|
|
|
|
|
|
+# define TOKEN_NAME 1
|
|
|
|
|
+# define TOKEN_STRING 2
|
|
|
|
|
+# define TOKEN_INTEGER 3
|
|
|
|
|
+# define TOKEN_GUID 5
|
|
|
|
|
+# define TOKEN_INTEGER_LIST 6
|
|
|
|
|
+# define TOKEN_REALNUM_LIST 7
|
|
|
|
|
+# define TOKEN_OBRACE 10
|
|
|
|
|
+# define TOKEN_CBRACE 11
|
|
|
|
|
+# define TOKEN_OPAREN 12
|
|
|
|
|
+# define TOKEN_CPAREN 13
|
|
|
|
|
+# define TOKEN_OBRACKET 14
|
|
|
|
|
+# define TOKEN_CBRACKET 15
|
|
|
|
|
+# define TOKEN_OANGLE 16
|
|
|
|
|
+# define TOKEN_CANGLE 17
|
|
|
|
|
+# define TOKEN_DOT 18
|
|
|
|
|
+# define TOKEN_COMMA 19
|
|
|
|
|
+# define TOKEN_SEMICOLON 20
|
|
|
|
|
+# define TOKEN_TEMPLATE 31
|
|
|
|
|
+# define TOKEN_WORD 40
|
|
|
|
|
+# define TOKEN_DWORD 41
|
|
|
|
|
+# define TOKEN_FLOAT 42
|
|
|
|
|
+# define TOKEN_DOUBLE 43
|
|
|
|
|
+# define TOKEN_CHAR 44
|
|
|
|
|
+# define TOKEN_UCHAR 45
|
|
|
|
|
+# define TOKEN_SWORD 46
|
|
|
|
|
+# define TOKEN_SDWORD 47
|
|
|
|
|
+# define TOKEN_VOID 48
|
|
|
|
|
+# define TOKEN_LPSTR 49
|
|
|
|
|
+# define TOKEN_UNICODE 50
|
|
|
|
|
+# define TOKEN_CSTRING 51
|
|
|
|
|
+# define TOKEN_ARRAY 52
|
|
|
|
|
+
|
|
|
|
|
+#line 12 "xParser.yxx"
|
|
|
|
|
|
|
|
#include "xLexerDefs.h"
|
|
#include "xLexerDefs.h"
|
|
|
#include "xParserDefs.h"
|
|
#include "xParserDefs.h"
|
|
@@ -37,6 +50,8 @@
|
|
|
#include "xFileTemplate.h"
|
|
#include "xFileTemplate.h"
|
|
|
#include "xFileDataDef.h"
|
|
#include "xFileDataDef.h"
|
|
|
#include "xFileArrayDef.h"
|
|
#include "xFileArrayDef.h"
|
|
|
|
|
+#include "xFileDataObjectTemplate.h"
|
|
|
|
|
+#include "pointerTo.h"
|
|
|
#include "dcast.h"
|
|
#include "dcast.h"
|
|
|
|
|
|
|
|
// Because our token type contains objects of type string, which
|
|
// Because our token type contains objects of type string, which
|
|
@@ -49,7 +64,7 @@
|
|
|
|
|
|
|
|
static XFile *x_file = (XFile *)NULL;
|
|
static XFile *x_file = (XFile *)NULL;
|
|
|
static XFileNode *current_node = (XFileNode *)NULL;
|
|
static XFileNode *current_node = (XFileNode *)NULL;
|
|
|
-static XFileDataDef *current_data_def = (XFileDataDef *)NULL;
|
|
|
|
|
|
|
+static PT(XFileDataDef) current_data_def = (XFileDataDef *)NULL;
|
|
|
|
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
////////////////////////////////////////////////////////////////////
|
|
|
// Defining the interface to the parser.
|
|
// Defining the interface to the parser.
|
|
@@ -74,29 +89,30 @@ x_cleanup_parser() {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
-#define YYFINAL 84
|
|
|
|
|
|
|
+#define YYFINAL 96
|
|
|
#define YYFLAG -32768
|
|
#define YYFLAG -32768
|
|
|
-#define YYNTBASE 27
|
|
|
|
|
|
|
+#define YYNTBASE 34
|
|
|
|
|
|
|
|
/* YYTRANSLATE(YYLEX) -- Bison token number corresponding to YYLEX. */
|
|
/* YYTRANSLATE(YYLEX) -- Bison token number corresponding to YYLEX. */
|
|
|
-#define YYTRANSLATE(x) ((unsigned)(x) <= 274 ? yytranslate[x] : 46)
|
|
|
|
|
|
|
+#define YYTRANSLATE(x) ((unsigned)(x) <= 256 ? yytranslate[x] : 67)
|
|
|
|
|
|
|
|
/* YYTRANSLATE[YYLEX] -- Bison token number corresponding to YYLEX. */
|
|
/* YYTRANSLATE[YYLEX] -- Bison token number corresponding to YYLEX. */
|
|
|
static const char yytranslate[] =
|
|
static const char yytranslate[] =
|
|
|
{
|
|
{
|
|
|
- 0, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
|
|
|
|
+ 0, 3, 4, 5, 2, 6, 7, 8, 2, 2,
|
|
|
|
|
+ 9, 10, 11, 12, 13, 14, 15, 16, 17, 18,
|
|
|
|
|
+ 19, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
|
|
+ 2, 20, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
|
|
+ 21, 22, 23, 24, 25, 26, 27, 28, 29, 30,
|
|
|
|
|
+ 31, 32, 33, 2, 2, 2, 2, 2, 2, 2,
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
- 2, 2, 2, 2, 26, 2, 2, 2, 2, 2,
|
|
|
|
|
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 23,
|
|
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
- 2, 24, 2, 25, 2, 2, 2, 2, 2, 2,
|
|
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
- 2, 2, 2, 21, 2, 22, 2, 2, 2, 2,
|
|
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
@@ -108,37 +124,39 @@ static const char yytranslate[] =
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
- 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
|
|
- 2, 2, 2, 2, 2, 2, 1, 3, 4, 5,
|
|
|
|
|
- 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
|
|
|
|
|
- 16, 17, 18, 19, 20
|
|
|
|
|
|
|
+ 2, 2, 2, 2, 2, 2, 1
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
#if YYDEBUG
|
|
#if YYDEBUG
|
|
|
static const short yyprhs[] =
|
|
static const short yyprhs[] =
|
|
|
{
|
|
{
|
|
|
- 0, 0, 2, 5, 8, 9, 18, 20, 24, 26,
|
|
|
|
|
- 27, 32, 35, 38, 41, 44, 47, 50, 53, 56,
|
|
|
|
|
- 59, 62, 65, 67, 70, 74, 78, 80, 84, 88,
|
|
|
|
|
- 91, 96, 97, 104, 106, 109, 111, 113, 115, 117,
|
|
|
|
|
- 119, 121, 123, 127, 129, 131, 133, 135
|
|
|
|
|
|
|
+ 0, 0, 2, 5, 8, 9, 17, 22, 24, 26,
|
|
|
|
|
+ 28, 30, 32, 34, 37, 39, 41, 43, 47, 52,
|
|
|
|
|
+ 56, 58, 60, 62, 64, 66, 68, 70, 72, 74,
|
|
|
|
|
+ 76, 78, 81, 84, 86, 89, 93, 95, 97, 99,
|
|
|
|
|
+ 102, 104, 107, 109, 111, 113, 115, 117, 119, 123,
|
|
|
|
|
+ 124, 132, 134, 137, 139, 141, 143, 145, 148, 150,
|
|
|
|
|
+ 152, 154, 156, 158, 160, 165
|
|
|
};
|
|
};
|
|
|
static const short yyrhs[] =
|
|
static const short yyrhs[] =
|
|
|
{
|
|
{
|
|
|
- 45, 0, 27, 28, 0, 27, 38, 0, 0, 16,
|
|
|
|
|
- 6, 21, 7, 29, 30, 36, 22, 0, 45, 0,
|
|
|
|
|
- 30, 31, 23, 0, 33, 0, 0, 8, 33, 32,
|
|
|
|
|
- 34, 0, 19, 43, 0, 13, 43, 0, 14, 43,
|
|
|
|
|
- 0, 12, 43, 0, 10, 43, 0, 17, 43, 0,
|
|
|
|
|
- 9, 43, 0, 15, 43, 0, 11, 43, 0, 18,
|
|
|
|
|
- 43, 0, 6, 43, 0, 35, 0, 34, 35, 0,
|
|
|
|
|
- 24, 3, 25, 0, 24, 6, 25, 0, 45, 0,
|
|
|
|
|
- 24, 20, 25, 0, 24, 37, 25, 0, 6, 44,
|
|
|
|
|
- 0, 37, 26, 6, 44, 0, 0, 6, 43, 21,
|
|
|
|
|
- 39, 40, 22, 0, 45, 0, 40, 41, 0, 38,
|
|
|
|
|
- 0, 42, 0, 3, 0, 4, 0, 5, 0, 23,
|
|
|
|
|
- 0, 26, 0, 21, 6, 22, 0, 45, 0, 6,
|
|
|
|
|
- 0, 45, 0, 7, 0, 0
|
|
|
|
|
|
|
+ 66, 0, 34, 35, 0, 34, 57, 0, 0, 20,
|
|
|
|
|
+ 52, 9, 54, 36, 37, 10, 0, 38, 13, 39,
|
|
|
|
|
+ 14, 0, 40, 0, 66, 0, 40, 0, 56, 0,
|
|
|
|
|
+ 50, 0, 41, 0, 40, 41, 0, 42, 0, 43,
|
|
|
|
|
+ 0, 44, 0, 45, 53, 19, 0, 33, 46, 47,
|
|
|
|
|
+ 19, 0, 52, 53, 19, 0, 21, 0, 22, 0,
|
|
|
|
|
+ 23, 0, 24, 0, 25, 0, 26, 0, 27, 0,
|
|
|
|
|
+ 28, 0, 30, 0, 31, 0, 32, 0, 45, 52,
|
|
|
|
|
+ 0, 52, 52, 0, 48, 0, 47, 48, 0, 13,
|
|
|
|
|
+ 49, 14, 0, 5, 0, 52, 0, 51, 0, 50,
|
|
|
|
|
+ 51, 0, 52, 0, 52, 6, 0, 3, 0, 66,
|
|
|
|
|
+ 0, 52, 0, 6, 0, 66, 0, 54, 0, 17,
|
|
|
|
|
+ 17, 17, 0, 0, 52, 53, 9, 58, 55, 59,
|
|
|
|
|
+ 10, 0, 60, 0, 59, 60, 0, 65, 0, 57,
|
|
|
|
|
+ 0, 61, 0, 62, 0, 63, 64, 0, 64, 0,
|
|
|
|
|
+ 7, 0, 8, 0, 4, 0, 19, 0, 18, 0,
|
|
|
|
|
+ 9, 52, 55, 10, 0, 0
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
#endif
|
|
#endif
|
|
@@ -147,11 +165,13 @@ static const short yyrhs[] =
|
|
|
/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
|
|
/* YYRLINE[YYN] -- source line where rule number YYN was defined. */
|
|
|
static const short yyrline[] =
|
|
static const short yyrline[] =
|
|
|
{
|
|
{
|
|
|
- 0, 72, 74, 75, 78, 78, 93, 95, 98, 103,
|
|
|
|
|
- 103, 111, 116, 120, 124, 128, 132, 136, 140, 144,
|
|
|
|
|
- 148, 152, 158, 160, 163, 168, 179, 181, 182, 185,
|
|
|
|
|
- 189, 194, 194, 204, 206, 209, 213, 216, 219, 222,
|
|
|
|
|
- 225, 228, 233, 237, 242, 245, 250, 253
|
|
|
|
|
|
|
+ 0, 104, 106, 107, 110, 110, 125, 127, 130, 132,
|
|
|
|
|
+ 135, 140, 143, 145, 148, 150, 151, 154, 162, 166,
|
|
|
|
|
+ 179, 184, 188, 192, 196, 200, 204, 208, 212, 216,
|
|
|
|
|
+ 220, 226, 232, 244, 246, 249, 253, 258, 269, 273,
|
|
|
|
|
+ 278, 288, 303, 307, 312, 315, 319, 324, 327, 331,
|
|
|
|
|
+ 331, 353, 355, 358, 362, 365, 368, 371, 374, 379,
|
|
|
|
|
+ 383, 387, 391, 393, 396, 400
|
|
|
};
|
|
};
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
@@ -161,36 +181,48 @@ static const short yyrline[] =
|
|
|
/* YYTNAME[TOKEN_NUM] -- String name of the token TOKEN_NUM. */
|
|
/* YYTNAME[TOKEN_NUM] -- String name of the token TOKEN_NUM. */
|
|
|
static const char *const yytname[] =
|
|
static const char *const yytname[] =
|
|
|
{
|
|
{
|
|
|
- "$", "error", "$undefined.", "INTEGER", "REAL", "STRING", "IDENTIFIER",
|
|
|
|
|
- "WINDOWS_GUID", "KW_ARRAY", "KW_BYTE", "KW_CHAR", "KW_CSTRING",
|
|
|
|
|
- "KW_DOUBLE", "KW_DWORD", "KW_FLOAT", "KW_STRING", "KW_TEMPLATE",
|
|
|
|
|
- "KW_UCHAR", "KW_UNICODE", "KW_WORD", "ELLIPSIS", "'{'", "'}'", "';'",
|
|
|
|
|
- "'['", "']'", "','", "xfile", "xtemplate", "@1", "template_members",
|
|
|
|
|
- "template_member", "@2", "data_def", "array_dimensions", "array_level",
|
|
|
|
|
- "template_restrictions", "template_list", "data_object", "@3",
|
|
|
|
|
- "data_object_members", "data_object_member", "data_reference",
|
|
|
|
|
- "optional_identifier", "optional_guid", "empty", 0
|
|
|
|
|
|
|
+ "$", "error", "$undefined.", "TOKEN_NAME", "TOKEN_STRING",
|
|
|
|
|
+ "TOKEN_INTEGER", "TOKEN_GUID", "TOKEN_INTEGER_LIST",
|
|
|
|
|
+ "TOKEN_REALNUM_LIST", "TOKEN_OBRACE", "TOKEN_CBRACE", "TOKEN_OPAREN",
|
|
|
|
|
+ "TOKEN_CPAREN", "TOKEN_OBRACKET", "TOKEN_CBRACKET", "TOKEN_OANGLE",
|
|
|
|
|
+ "TOKEN_CANGLE", "TOKEN_DOT", "TOKEN_COMMA", "TOKEN_SEMICOLON",
|
|
|
|
|
+ "TOKEN_TEMPLATE", "TOKEN_WORD", "TOKEN_DWORD", "TOKEN_FLOAT",
|
|
|
|
|
+ "TOKEN_DOUBLE", "TOKEN_CHAR", "TOKEN_UCHAR", "TOKEN_SWORD",
|
|
|
|
|
+ "TOKEN_SDWORD", "TOKEN_VOID", "TOKEN_LPSTR", "TOKEN_UNICODE",
|
|
|
|
|
+ "TOKEN_CSTRING", "TOKEN_ARRAY", "xfile", "template", "@1",
|
|
|
|
|
+ "template_parts", "template_members_part", "template_option_info",
|
|
|
|
|
+ "template_members_list", "template_members", "primitive", "array",
|
|
|
|
|
+ "template_reference", "primitive_type", "array_data_type",
|
|
|
|
|
+ "dimension_list", "dimension", "dimension_size", "template_option_list",
|
|
|
|
|
+ "template_option_part", "name", "optional_name", "class_id",
|
|
|
|
|
+ "optional_class_id", "ellipsis", "object", "@2", "data_parts_list",
|
|
|
|
|
+ "data_part", "integer_list", "realnum_list", "string", "list_separator",
|
|
|
|
|
+ "data_reference", "empty", 0
|
|
|
};
|
|
};
|
|
|
#endif
|
|
#endif
|
|
|
|
|
|
|
|
/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
|
|
/* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */
|
|
|
static const short yyr1[] =
|
|
static const short yyr1[] =
|
|
|
{
|
|
{
|
|
|
- 0, 27, 27, 27, 29, 28, 30, 30, 31, 32,
|
|
|
|
|
- 31, 33, 33, 33, 33, 33, 33, 33, 33, 33,
|
|
|
|
|
- 33, 33, 34, 34, 35, 35, 36, 36, 36, 37,
|
|
|
|
|
- 37, 39, 38, 40, 40, 41, 41, 41, 41, 41,
|
|
|
|
|
- 41, 41, 42, 43, 43, 44, 44, 45
|
|
|
|
|
|
|
+ 0, 34, 34, 34, 36, 35, 37, 37, 38, 38,
|
|
|
|
|
+ 39, 39, 40, 40, 41, 41, 41, 42, 43, 44,
|
|
|
|
|
+ 45, 45, 45, 45, 45, 45, 45, 45, 45, 45,
|
|
|
|
|
+ 45, 46, 46, 47, 47, 48, 49, 49, 50, 50,
|
|
|
|
|
+ 51, 51, 52, 53, 53, 54, 55, 55, 56, 58,
|
|
|
|
|
+ 57, 59, 59, 60, 60, 60, 60, 60, 60, 61,
|
|
|
|
|
+ 62, 63, 64, 64, 65, 66
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
|
|
/* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */
|
|
|
static const short yyr2[] =
|
|
static const short yyr2[] =
|
|
|
{
|
|
{
|
|
|
- 0, 1, 2, 2, 0, 8, 1, 3, 1, 0,
|
|
|
|
|
- 4, 2, 2, 2, 2, 2, 2, 2, 2, 2,
|
|
|
|
|
- 2, 2, 1, 2, 3, 3, 1, 3, 3, 2,
|
|
|
|
|
- 4, 0, 6, 1, 2, 1, 1, 1, 1, 1,
|
|
|
|
|
- 1, 1, 3, 1, 1, 1, 1, 0
|
|
|
|
|
|
|
+ 0, 1, 2, 2, 0, 7, 4, 1, 1, 1,
|
|
|
|
|
+ 1, 1, 1, 2, 1, 1, 1, 3, 4, 3,
|
|
|
|
|
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
|
|
|
|
|
+ 1, 2, 2, 1, 2, 3, 1, 1, 1, 2,
|
|
|
|
|
+ 1, 2, 1, 1, 1, 1, 1, 1, 3, 0,
|
|
|
|
|
+ 7, 1, 2, 1, 1, 1, 1, 2, 1, 1,
|
|
|
|
|
+ 1, 1, 1, 1, 4, 0
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
/* YYDEFACT[S] -- default rule to reduce with in state S when YYTABLE
|
|
/* YYDEFACT[S] -- default rule to reduce with in state S when YYTABLE
|
|
@@ -198,68 +230,82 @@ static const short yyr2[] =
|
|
|
error. */
|
|
error. */
|
|
|
static const short yydefact[] =
|
|
static const short yydefact[] =
|
|
|
{
|
|
{
|
|
|
- 47, 0, 1, 47, 0, 2, 3, 44, 0, 43,
|
|
|
|
|
- 0, 31, 0, 47, 4, 0, 33, 47, 37, 38,
|
|
|
|
|
- 39, 0, 32, 40, 41, 35, 34, 36, 47, 6,
|
|
|
|
|
- 0, 47, 0, 47, 47, 47, 47, 47, 47, 47,
|
|
|
|
|
- 47, 47, 47, 0, 0, 8, 0, 26, 42, 21,
|
|
|
|
|
- 9, 17, 15, 19, 14, 12, 13, 18, 16, 20,
|
|
|
|
|
- 11, 47, 0, 0, 7, 5, 0, 46, 29, 45,
|
|
|
|
|
- 27, 28, 0, 0, 10, 22, 47, 0, 0, 23,
|
|
|
|
|
- 30, 24, 25, 0, 0
|
|
|
|
|
|
|
+ 65, 0, 1, 42, 0, 2, 65, 3, 0, 44,
|
|
|
|
|
+ 0, 43, 0, 49, 45, 4, 65, 65, 47, 0,
|
|
|
|
|
+ 46, 20, 21, 22, 23, 24, 25, 26, 27, 28,
|
|
|
|
|
+ 29, 30, 0, 0, 0, 7, 12, 14, 15, 16,
|
|
|
|
|
+ 65, 65, 8, 61, 59, 60, 0, 63, 62, 54,
|
|
|
|
|
+ 0, 51, 55, 56, 0, 58, 53, 0, 0, 0,
|
|
|
|
|
+ 5, 0, 13, 0, 0, 65, 50, 52, 57, 31,
|
|
|
|
|
+ 0, 0, 33, 32, 0, 0, 11, 38, 40, 10,
|
|
|
|
|
+ 17, 19, 0, 36, 0, 37, 18, 34, 0, 6,
|
|
|
|
|
+ 39, 41, 64, 35, 48, 0, 0
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
static const short yydefgoto[] =
|
|
static const short yydefgoto[] =
|
|
|
{
|
|
{
|
|
|
- 1, 5, 17, 28, 44, 66, 45, 74, 75, 46,
|
|
|
|
|
- 63, 6, 13, 15, 26, 27, 8, 68, 9
|
|
|
|
|
|
|
+ 1, 5, 17, 33, 34, 75, 35, 36, 37, 38,
|
|
|
|
|
+ 39, 40, 58, 71, 72, 84, 76, 77, 6, 10,
|
|
|
|
|
+ 18, 19, 79, 49, 16, 50, 51, 52, 53, 54,
|
|
|
|
|
+ 55, 56, 11
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
static const short yypact[] =
|
|
static const short yypact[] =
|
|
|
{
|
|
{
|
|
|
- -32768, 6,-32768, 1, 8,-32768,-32768,-32768, -6,-32768,
|
|
|
|
|
- -5,-32768, 11,-32768,-32768, -2,-32768,-32768,-32768,-32768,
|
|
|
|
|
- -32768, 19,-32768,-32768,-32768,-32768,-32768,-32768, 21,-32768,
|
|
|
|
|
- 4, 1, 37, 1, 1, 1, 1, 1, 1, 1,
|
|
|
|
|
- 1, 1, 1, 3, 14,-32768, 20,-32768,-32768,-32768,
|
|
|
|
|
|
|
+ -32768, 1,-32768,-32768, 6,-32768, 6,-32768, 9,-32768,
|
|
|
|
|
+ 18,-32768, 34,-32768,-32768,-32768, 34, 70,-32768, 26,
|
|
|
-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
|
|
-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,-32768,
|
|
|
- -32768, 34, 28, -15,-32768,-32768, 33,-32768,-32768,-32768,
|
|
|
|
|
- -32768,-32768, 38, 2, 33,-32768, 34, 47, 48,-32768,
|
|
|
|
|
- -32768,-32768,-32768, 58,-32768
|
|
|
|
|
|
|
+ -32768,-32768, 87, 22, 28, 56,-32768,-32768,-32768,-32768,
|
|
|
|
|
+ 6, 6,-32768,-32768,-32768,-32768, 6,-32768,-32768,-32768,
|
|
|
|
|
+ 7,-32768,-32768,-32768, 20,-32768,-32768, 6, 30, 6,
|
|
|
|
|
+ -32768, 5,-32768, 27, 29, 34,-32768,-32768,-32768,-32768,
|
|
|
|
|
+ 2, -7,-32768,-32768, 32, 33, 6,-32768, 44,-32768,
|
|
|
|
|
+ -32768,-32768, 41,-32768, 38,-32768,-32768,-32768, 37,-32768,
|
|
|
|
|
+ -32768,-32768,-32768,-32768,-32768, 58,-32768
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
static const short yypgoto[] =
|
|
static const short yypgoto[] =
|
|
|
{
|
|
{
|
|
|
- -32768,-32768,-32768,-32768,-32768,-32768, 27,-32768, 5,-32768,
|
|
|
|
|
- -32768, 59,-32768,-32768,-32768,-32768, 29, -1, 0
|
|
|
|
|
|
|
+ -32768,-32768,-32768,-32768,-32768,-32768,-32768, 21,-32768,-32768,
|
|
|
|
|
+ -32768, 31,-32768,-32768, -11,-32768,-32768, -15, -4, -17,
|
|
|
|
|
+ 50, -1,-32768, 64,-32768,-32768, 17,-32768,-32768,-32768,
|
|
|
|
|
+ 16,-32768, 3
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
-#define YYLAST 79
|
|
|
|
|
|
|
+#define YYLAST 119
|
|
|
|
|
|
|
|
|
|
|
|
|
static const short yytable[] =
|
|
static const short yytable[] =
|
|
|
{
|
|
{
|
|
|
- 2, 18, 19, 20, 3, 77, 83, 7, 78, 61,
|
|
|
|
|
- 71, 72, 3, 16, 10, 11, 12, 29, 14, 21,
|
|
|
|
|
- 22, 23, 4, 62, 24, 30, 48, 31, 47, 32,
|
|
|
|
|
- 33, 34, 35, 36, 37, 38, 39, 64, 40, 41,
|
|
|
|
|
- 42, 67, 65, 31, 76, 43, 33, 34, 35, 36,
|
|
|
|
|
- 37, 38, 39, 70, 40, 41, 42, 73, 84, 50,
|
|
|
|
|
- 49, 69, 51, 52, 53, 54, 55, 56, 57, 58,
|
|
|
|
|
- 59, 60, 81, 82, 25, 80, 69, 0, 0, 79
|
|
|
|
|
|
|
+ 8, 95, 9, 2, 3, 3, 70, 83, 3, 3,
|
|
|
|
|
+ 3, 43, 86, 41, 44, 45, 46, 66, 12, 20,
|
|
|
|
|
+ 42, 4, 74, 63, 64, 47, 48, 13, 59, 3,
|
|
|
|
|
+ 43, 41, 60, 44, 45, 46, 9, 9, 47, 48,
|
|
|
|
|
+ 14, 61, 65, 70, 47, 48, 80, 89, 81, 88,
|
|
|
|
|
+ 91, 92, 93, 69, 94, 73, 62, 78, 96, 3,
|
|
|
|
|
+ 87, 90, 15, 57, 82, 7, 85, 67, 20, -9,
|
|
|
|
|
+ 68, 0, 78, 3, 0, 0, 0, 21, 22, 23,
|
|
|
|
|
+ 24, 25, 26, 27, 28, 0, 29, 30, 31, 32,
|
|
|
|
|
+ 3, 21, 22, 23, 24, 25, 26, 27, 28, 0,
|
|
|
|
|
+ 29, 30, 31, 32, 0, 0, 0, 0, 21, 22,
|
|
|
|
|
+ 23, 24, 25, 26, 27, 28, 0, 29, 30, 31
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
static const short yycheck[] =
|
|
static const short yycheck[] =
|
|
|
{
|
|
{
|
|
|
- 0, 3, 4, 5, 6, 3, 0, 6, 6, 6,
|
|
|
|
|
- 25, 26, 6, 13, 6, 21, 21, 17, 7, 21,
|
|
|
|
|
- 22, 23, 16, 20, 26, 6, 22, 6, 28, 8,
|
|
|
|
|
- 9, 10, 11, 12, 13, 14, 15, 23, 17, 18,
|
|
|
|
|
- 19, 7, 22, 6, 6, 24, 9, 10, 11, 12,
|
|
|
|
|
- 13, 14, 15, 25, 17, 18, 19, 24, 0, 32,
|
|
|
|
|
- 31, 61, 33, 34, 35, 36, 37, 38, 39, 40,
|
|
|
|
|
- 41, 42, 25, 25, 15, 76, 76, -1, -1, 74
|
|
|
|
|
|
|
+ 4, 0, 6, 0, 3, 3, 13, 5, 3, 3,
|
|
|
|
|
+ 3, 4, 19, 17, 7, 8, 9, 10, 9, 16,
|
|
|
|
|
+ 17, 20, 17, 40, 41, 18, 19, 9, 32, 3,
|
|
|
|
|
+ 4, 35, 10, 7, 8, 9, 40, 41, 18, 19,
|
|
|
|
|
+ 6, 13, 46, 13, 18, 19, 19, 14, 19, 17,
|
|
|
|
|
+ 6, 10, 14, 57, 17, 59, 35, 61, 0, 3,
|
|
|
|
|
+ 71, 76, 12, 32, 65, 1, 70, 50, 65, 13,
|
|
|
|
|
+ 54, -1, 76, 3, -1, -1, -1, 21, 22, 23,
|
|
|
|
|
+ 24, 25, 26, 27, 28, -1, 30, 31, 32, 33,
|
|
|
|
|
+ 3, 21, 22, 23, 24, 25, 26, 27, 28, -1,
|
|
|
|
|
+ 30, 31, 32, 33, -1, -1, -1, -1, 21, 22,
|
|
|
|
|
+ 23, 24, 25, 26, 27, 28, -1, 30, 31, 32
|
|
|
};
|
|
};
|
|
|
/* -*-C-*- Note some compilers choke on comments on `#line' lines. */
|
|
/* -*-C-*- Note some compilers choke on comments on `#line' lines. */
|
|
|
#line 3 "/usr/share/bison/bison.simple"
|
|
#line 3 "/usr/share/bison/bison.simple"
|
|
@@ -969,7 +1015,7 @@ yyreduce:
|
|
|
switch (yyn) {
|
|
switch (yyn) {
|
|
|
|
|
|
|
|
case 4:
|
|
case 4:
|
|
|
-#line 80 "xParser.yxx"
|
|
|
|
|
|
|
+#line 112 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
yyval.u.node = current_node;
|
|
yyval.u.node = current_node;
|
|
|
XFileTemplate *templ = new XFileTemplate(yyvsp[-2].str, yyvsp[0].guid);
|
|
XFileTemplate *templ = new XFileTemplate(yyvsp[-2].str, yyvsp[0].guid);
|
|
@@ -978,173 +1024,238 @@ case 4:
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
case 5:
|
|
case 5:
|
|
|
-#line 87 "xParser.yxx"
|
|
|
|
|
|
|
+#line 119 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
yyval.u.node = current_node;
|
|
yyval.u.node = current_node;
|
|
|
- current_node = yyvsp[-3].u.node;
|
|
|
|
|
|
|
+ current_node = yyvsp[-2].u.node;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 8:
|
|
|
|
|
-#line 100 "xParser.yxx"
|
|
|
|
|
|
|
+case 10:
|
|
|
|
|
+#line 137 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- current_node->add_child(yyvsp[0].u.data_def);
|
|
|
|
|
|
|
+ DCAST(XFileTemplate, current_node)->set_open(true);
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 9:
|
|
|
|
|
-#line 104 "xParser.yxx"
|
|
|
|
|
|
|
+case 17:
|
|
|
|
|
+#line 156 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- current_node->add_child(yyvsp[0].u.data_def);
|
|
|
|
|
- current_data_def = yyvsp[0].u.data_def;
|
|
|
|
|
|
|
+ current_data_def = new XFileDataDef(yyvsp[-2].u.primitive_type, yyvsp[-1].str);
|
|
|
|
|
+ current_node->add_child(current_data_def);
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 11:
|
|
|
|
|
-#line 113 "xParser.yxx"
|
|
|
|
|
|
|
+case 19:
|
|
|
|
|
+#line 168 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_word, yyvsp[0].str);
|
|
|
|
|
|
|
+ XFileTemplate *xtemplate = x_file->find_template(yyvsp[-2].str);
|
|
|
|
|
+ if (xtemplate == (XFileTemplate *)NULL) {
|
|
|
|
|
+ yyerror("Unknown template: " + yyvsp[-2].str);
|
|
|
|
|
+ } else {
|
|
|
|
|
+ current_data_def = new XFileDataDef(XFileDataDef::T_template, yyvsp[-1].str, xtemplate);
|
|
|
|
|
+ current_node->add_child(current_data_def);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 12:
|
|
|
|
|
-#line 117 "xParser.yxx"
|
|
|
|
|
|
|
+case 20:
|
|
|
|
|
+#line 181 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_dword, yyvsp[0].str);
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_word;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 13:
|
|
|
|
|
-#line 121 "xParser.yxx"
|
|
|
|
|
|
|
+case 21:
|
|
|
|
|
+#line 185 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_float, yyvsp[0].str);
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_dword;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 14:
|
|
|
|
|
-#line 125 "xParser.yxx"
|
|
|
|
|
|
|
+case 22:
|
|
|
|
|
+#line 189 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_double, yyvsp[0].str);
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_float;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 15:
|
|
|
|
|
-#line 129 "xParser.yxx"
|
|
|
|
|
|
|
+case 23:
|
|
|
|
|
+#line 193 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_char, yyvsp[0].str);
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_double;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 16:
|
|
|
|
|
-#line 133 "xParser.yxx"
|
|
|
|
|
|
|
+case 24:
|
|
|
|
|
+#line 197 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_uchar, yyvsp[0].str);
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_char;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 17:
|
|
|
|
|
-#line 137 "xParser.yxx"
|
|
|
|
|
|
|
+case 25:
|
|
|
|
|
+#line 201 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_byte, yyvsp[0].str);
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_uchar;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 18:
|
|
|
|
|
-#line 141 "xParser.yxx"
|
|
|
|
|
|
|
+case 26:
|
|
|
|
|
+#line 205 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_string, yyvsp[0].str);
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_sword;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 19:
|
|
|
|
|
-#line 145 "xParser.yxx"
|
|
|
|
|
|
|
+case 27:
|
|
|
|
|
+#line 209 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_cstring, yyvsp[0].str);
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_sdword;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 20:
|
|
|
|
|
-#line 149 "xParser.yxx"
|
|
|
|
|
|
|
+case 28:
|
|
|
|
|
+#line 213 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_unicode, yyvsp[0].str);
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_string;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 21:
|
|
|
|
|
-#line 153 "xParser.yxx"
|
|
|
|
|
|
|
+case 29:
|
|
|
|
|
+#line 217 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.u.data_def = new XFileDataDef(XFileDataDef::T_word, yyvsp[0].str);
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_unicode;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 24:
|
|
|
|
|
-#line 165 "xParser.yxx"
|
|
|
|
|
|
|
+case 30:
|
|
|
|
|
+#line 221 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- current_data_def->add_array_def(XFileArrayDef(yyvsp[-1].u.s_int));
|
|
|
|
|
|
|
+ yyval.u.primitive_type = XFileDataDef::T_cstring;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 25:
|
|
|
|
|
-#line 169 "xParser.yxx"
|
|
|
|
|
|
|
+case 31:
|
|
|
|
|
+#line 228 "xParser.yxx"
|
|
|
|
|
+{
|
|
|
|
|
+ current_data_def = new XFileDataDef(yyvsp[-1].u.primitive_type, yyvsp[0].str);
|
|
|
|
|
+ current_node->add_child(current_data_def);
|
|
|
|
|
+}
|
|
|
|
|
+ break;
|
|
|
|
|
+case 32:
|
|
|
|
|
+#line 233 "xParser.yxx"
|
|
|
|
|
+{
|
|
|
|
|
+ XFileTemplate *xtemplate = x_file->find_template(yyvsp[-1].str);
|
|
|
|
|
+ if (xtemplate == (XFileTemplate *)NULL) {
|
|
|
|
|
+ yyerror("Unknown template: " + yyvsp[-1].str);
|
|
|
|
|
+ } else {
|
|
|
|
|
+ current_data_def = new XFileDataDef(XFileDataDef::T_template, yyvsp[0].str, xtemplate);
|
|
|
|
|
+ current_node->add_child(current_data_def);
|
|
|
|
|
+ }
|
|
|
|
|
+}
|
|
|
|
|
+ break;
|
|
|
|
|
+case 36:
|
|
|
|
|
+#line 255 "xParser.yxx"
|
|
|
|
|
+{
|
|
|
|
|
+ current_data_def->add_array_def(XFileArrayDef(yyvsp[0].u.number));
|
|
|
|
|
+}
|
|
|
|
|
+ break;
|
|
|
|
|
+case 37:
|
|
|
|
|
+#line 259 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- XFileNode *data_def = current_node->find_child(yyvsp[-1].str);
|
|
|
|
|
|
|
+ XFileNode *data_def = current_node->find_child(yyvsp[0].str);
|
|
|
if (data_def == (XFileNode *)NULL) {
|
|
if (data_def == (XFileNode *)NULL) {
|
|
|
- yyerror("Unknown identifier: " + yyvsp[-1].str);
|
|
|
|
|
|
|
+ yyerror("Unknown identifier: " + yyvsp[0].str);
|
|
|
} else {
|
|
} else {
|
|
|
current_data_def->add_array_def(XFileArrayDef(DCAST(XFileDataDef, data_def)));
|
|
current_data_def->add_array_def(XFileArrayDef(DCAST(XFileDataDef, data_def)));
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 29:
|
|
|
|
|
-#line 187 "xParser.yxx"
|
|
|
|
|
|
|
+case 38:
|
|
|
|
|
+#line 271 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 30:
|
|
|
|
|
-#line 190 "xParser.yxx"
|
|
|
|
|
|
|
+case 39:
|
|
|
|
|
+#line 274 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 31:
|
|
|
|
|
-#line 196 "xParser.yxx"
|
|
|
|
|
|
|
+case 40:
|
|
|
|
|
+#line 280 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
|
|
+ XFileTemplate *xtemplate = x_file->find_template(yyvsp[0].str);
|
|
|
|
|
+ if (xtemplate == (XFileTemplate *)NULL) {
|
|
|
|
|
+ yyerror("Unknown template: " + yyvsp[0].str);
|
|
|
|
|
+ } else {
|
|
|
|
|
+ DCAST(XFileTemplate, current_node)->add_option(xtemplate);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 32:
|
|
|
|
|
-#line 199 "xParser.yxx"
|
|
|
|
|
|
|
+case 41:
|
|
|
|
|
+#line 289 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
|
|
+ XFileTemplate *xtemplate = x_file->find_template(yyvsp[0].guid);
|
|
|
|
|
+ if (xtemplate == (XFileTemplate *)NULL) {
|
|
|
|
|
+ yyerror("Unknown template: " + yyvsp[-1].str);
|
|
|
|
|
+ } else {
|
|
|
|
|
+ if (xtemplate->get_name() != yyvsp[-1].str) {
|
|
|
|
|
+ xyywarning("GUID identifies template " + xtemplate->get_name() +
|
|
|
|
|
+ ", not " + yyvsp[-1].str);
|
|
|
|
|
+ }
|
|
|
|
|
+ DCAST(XFileTemplate, current_node)->add_option(xtemplate);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 35:
|
|
|
|
|
-#line 211 "xParser.yxx"
|
|
|
|
|
|
|
+case 43:
|
|
|
|
|
+#line 309 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
|
|
+ yyval.str = string();
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 36:
|
|
|
|
|
-#line 214 "xParser.yxx"
|
|
|
|
|
|
|
+case 46:
|
|
|
|
|
+#line 321 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
|
|
+ yyval.guid = WindowsGuid();
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 37:
|
|
|
|
|
-#line 217 "xParser.yxx"
|
|
|
|
|
|
|
+case 49:
|
|
|
|
|
+#line 333 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
|
|
+ XFileTemplate *xtemplate = x_file->find_template(yyvsp[-2].str);
|
|
|
|
|
+ yyval.u.node = current_node;
|
|
|
|
|
+
|
|
|
|
|
+ if (xtemplate == (XFileTemplate *)NULL) {
|
|
|
|
|
+ yyerror("Unknown template: " + yyvsp[-2].str);
|
|
|
|
|
+ } else {
|
|
|
|
|
+ XFileDataObjectTemplate *templ =
|
|
|
|
|
+ new XFileDataObjectTemplate(xtemplate, yyvsp[-1].str);
|
|
|
|
|
+ current_node->add_child(templ);
|
|
|
|
|
+ current_node = templ;
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 38:
|
|
|
|
|
-#line 220 "xParser.yxx"
|
|
|
|
|
|
|
+case 50:
|
|
|
|
|
+#line 347 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
|
|
+ yyval.u.node = current_node;
|
|
|
|
|
+ current_node = yyvsp[-3].u.node;
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 39:
|
|
|
|
|
-#line 223 "xParser.yxx"
|
|
|
|
|
|
|
+case 53:
|
|
|
|
|
+#line 360 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 40:
|
|
|
|
|
-#line 226 "xParser.yxx"
|
|
|
|
|
|
|
+case 54:
|
|
|
|
|
+#line 363 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 41:
|
|
|
|
|
-#line 229 "xParser.yxx"
|
|
|
|
|
|
|
+case 55:
|
|
|
|
|
+#line 366 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 43:
|
|
|
|
|
-#line 239 "xParser.yxx"
|
|
|
|
|
|
|
+case 56:
|
|
|
|
|
+#line 369 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.str = string();
|
|
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
-case 45:
|
|
|
|
|
-#line 247 "xParser.yxx"
|
|
|
|
|
|
|
+case 57:
|
|
|
|
|
+#line 372 "xParser.yxx"
|
|
|
|
|
+{
|
|
|
|
|
+}
|
|
|
|
|
+ break;
|
|
|
|
|
+case 58:
|
|
|
|
|
+#line 375 "xParser.yxx"
|
|
|
{
|
|
{
|
|
|
- yyval.guid = WindowsGuid();
|
|
|
|
|
}
|
|
}
|
|
|
break;
|
|
break;
|
|
|
}
|
|
}
|
|
@@ -1380,4 +1491,4 @@ yyreturn:
|
|
|
#endif
|
|
#endif
|
|
|
return yyresult;
|
|
return yyresult;
|
|
|
}
|
|
}
|
|
|
-#line 256 "xParser.yxx"
|
|
|
|
|
|
|
+#line 402 "xParser.yxx"
|