summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaymond Lu <songyulu@hdfgroup.org>2006-01-16 17:27:07 (GMT)
committerRaymond Lu <songyulu@hdfgroup.org>2006-01-16 17:27:07 (GMT)
commitda37fca10b287d3a9dee57ca59e6c4bd733463ae (patch)
treec85b7e7a73ad1e1941629cfe701d546de4db4f0e
parentf78ed9a18d7f632a52c69e2cc508bf4c4ff6d6bc (diff)
downloadhdf5-da37fca10b287d3a9dee57ca59e6c4bd733463ae.zip
hdf5-da37fca10b287d3a9dee57ca59e6c4bd733463ae.tar.gz
hdf5-da37fca10b287d3a9dee57ca59e6c4bd733463ae.tar.bz2
[svn-r11882] Purpose: Revision
Description: Revise a few details of H5LTtext_to_dtype() and H5LTdtype_to_text(), 1. changed the DDL definition of string, opaque, and compound types. 2. added a new parameter of H5LT_lang_t type to these two functions. Platforms tested: h5committest and fuss.
-rw-r--r--hl/src/H5LT.c115
-rw-r--r--hl/src/H5LT.h14
-rw-r--r--hl/src/H5LTanalyze.c852
-rw-r--r--hl/src/H5LTanalyze.l13
-rw-r--r--hl/src/H5LTparse.c498
-rw-r--r--hl/src/H5LTparse.h23
-rw-r--r--hl/src/H5LTparse.y120
-rw-r--r--hl/test/test_lite.c74
8 files changed, 954 insertions, 755 deletions
diff --git a/hl/src/H5LT.c b/hl/src/H5LT.c
index 10ce1c5..432d696 100644
--- a/hl/src/H5LT.c
+++ b/hl/src/H5LT.c
@@ -2007,10 +2007,18 @@ out:
*
*-------------------------------------------------------------------------
*/
-hid_t H5LTtext_to_dtype(const char *text)
+hid_t H5LTtext_to_dtype(const char *text, H5LT_lang_t lang_type)
{
extern int yyparse(void);
hid_t type_id;
+
+ if(lang_type <= H5LT_LANG_ERR || lang_type >= H5LT_NO_LANG)
+ goto out;
+
+ if(lang_type != H5LT_DDL) {
+ fprintf(stderr, "only DDL is supported for now.\n");
+ goto out;
+ }
input_len = strlen(text);
myinput = strdup(text);
@@ -2184,20 +2192,23 @@ out:
*
*-------------------------------------------------------------------------
*/
-herr_t H5LTdtype_to_text(hid_t dtype, char *str, size_t *len)
+herr_t H5LTdtype_to_text(hid_t dtype, char *str, H5LT_lang_t lang_type, size_t *len)
{
size_t str_len = INCREMENT;
char *text_str;
herr_t ret;
-
+
+ if(lang_type <= H5LT_LANG_ERR || lang_type >= H5LT_NO_LANG)
+ goto out;
+
if(len && !str) {
text_str = (char*)calloc(str_len, sizeof(char));
text_str[0]='\0';
- if((ret = H5LT_dtype_to_text(dtype, &text_str, &str_len, 1))<0)
+ if((ret = H5LT_dtype_to_text(dtype, &text_str, lang_type, &str_len, 1))<0)
goto out;
*len = strlen(text_str) + 1;
} else if(len && str) {
- if((ret = H5LT_dtype_to_text(dtype, &str, len, 0))<0)
+ if((ret = H5LT_dtype_to_text(dtype, &str, lang_type, len, 0))<0)
goto out;
str[*len-1] = '\0';
}
@@ -2225,7 +2236,8 @@ out:
*
*-------------------------------------------------------------------------
*/
-herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, size_t *slen, hbool_t no_user_buf)
+herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, H5LT_lang_t lang, size_t *slen,
+ hbool_t no_user_buf)
{
H5T_class_t tcls;
char tmp_str[256];
@@ -2241,6 +2253,11 @@ herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, size_t *slen, hbool_t no_u
*dt_str = tmp;
}
}
+
+ if(lang != H5LT_DDL) {
+ sprintf(*dt_str, "only DDL is supported for now");
+ goto out;
+ }
if((tcls = H5Tget_class(dtype))<0)
goto out;
@@ -2354,6 +2371,36 @@ herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, size_t *slen, hbool_t no_u
sprintf(*dt_str, "H5T_STRING {\n");
indent += COL;
+ indentation(indent + COL, *dt_str);
+
+ if(is_vlstr)
+ strcat(*dt_str, "STRSIZE H5T_VARIABLE;\n");
+ else {
+ sprintf(tmp_str, "STRSIZE %d;\n", (int)size);
+ strcat(*dt_str, tmp_str);
+ }
+
+ indentation(indent + COL, *dt_str);
+
+ if (str_pad == H5T_STR_NULLTERM)
+ strcat(*dt_str, "STRPAD H5T_STR_NULLTERM;\n");
+ else if (str_pad == H5T_STR_NULLPAD)
+ strcat(*dt_str, "STRPAD H5T_STR_NULLPAD;\n");
+ else if (str_pad == H5T_STR_SPACEPAD)
+ strcat(*dt_str, "STRPAD H5T_STR_SPACEPAD;\n");
+ else
+ strcat(*dt_str, "STRPAD H5T_STR_ERROR;\n");
+
+ indentation(indent + COL, *dt_str);
+
+ if (cset == H5T_CSET_ASCII)
+ strcat(*dt_str, "CSET H5T_CSET_ASCII;\n");
+ else if (cset == H5T_CSET_UTF8)
+ strcat(*dt_str, "CSET H5T_CSET_UTF8;\n");
+ else
+ strcat(*dt_str, "CSET unknown;\n");
+
+
/* Reproduce a C type string */
if((str_type = H5Tcopy(H5T_C_S1))<0)
goto out;
@@ -2433,33 +2480,6 @@ herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, size_t *slen, hbool_t no_u
strcat(*dt_str, "CTYPE unknown_one_character_type;\n ");
next:
- indentation(indent + COL, *dt_str);
-
- if(is_vlstr)
- strcat(*dt_str, "STRSIZE H5T_VARIABLE;\n");
- else {
- sprintf(tmp_str, "STRSIZE %d;\n", (int)size);
- strcat(*dt_str, tmp_str);
- }
-
- indentation(indent + COL, *dt_str);
-
- if (str_pad == H5T_STR_NULLTERM)
- strcat(*dt_str, "STRPAD H5T_STR_NULLTERM;\n");
- else if (str_pad == H5T_STR_NULLPAD)
- strcat(*dt_str, "STRPAD H5T_STR_NULLPAD;\n");
- else if (str_pad == H5T_STR_SPACEPAD)
- strcat(*dt_str, "STRPAD H5T_STR_SPACEPAD;\n");
- else
- strcat(*dt_str, "STRPAD H5T_STR_ERROR;\n");
-
- indentation(indent + COL, *dt_str);
-
- if (cset == H5T_CSET_ASCII)
- strcat(*dt_str, "CSET H5T_CSET_ASCII;\n");
- else
- strcat(*dt_str, "CSET unknown_cset;\n");
-
H5Tclose(str_type);
H5Tclose(tmp_type);
@@ -2478,7 +2498,11 @@ next:
indentation(indent + COL, *dt_str);
sprintf(tmp_str, "OPQ_SIZE %d;\n", H5Tget_size(dtype));
strcat(*dt_str, tmp_str);
-
+
+ indentation(indent + COL, *dt_str);
+ sprintf(tmp_str, "OPQ_TAG \"%s\";\n", H5Tget_tag(dtype));
+ strcat(*dt_str, tmp_str);
+
/* Print closing */
indent -= COL;
indentation(indent + COL, *dt_str);
@@ -2498,10 +2522,10 @@ next:
if((super = H5Tget_super(dtype))<0)
goto out;
- if(H5LTdtype_to_text(super, NULL, &super_len)<0)
+ if(H5LTdtype_to_text(super, NULL, lang, &super_len)<0)
goto out;
stmp = (char*)calloc(super_len, sizeof(char));
- if(H5LTdtype_to_text(super, stmp, &super_len)<0)
+ if(H5LTdtype_to_text(super, stmp, lang, &super_len)<0)
goto out;
strcat(*dt_str, stmp);
free(stmp);
@@ -2531,10 +2555,10 @@ next:
if((super = H5Tget_super(dtype))<0)
goto out;
- if(H5LTdtype_to_text(super, NULL, &super_len)<0)
+ if(H5LTdtype_to_text(super, NULL, lang, &super_len)<0)
goto out;
stmp = (char*)calloc(super_len, sizeof(char));
- if(H5LTdtype_to_text(super, stmp, &super_len)<0)
+ if(H5LTdtype_to_text(super, stmp, lang, &super_len)<0)
goto out;
strcat(*dt_str, stmp);
free(stmp);
@@ -2576,10 +2600,10 @@ next:
if((super = H5Tget_super(dtype))<0)
goto out;
- if(H5LTdtype_to_text(super, NULL, &super_len)<0)
+ if(H5LTdtype_to_text(super, NULL, lang, &super_len)<0)
goto out;
stmp = (char*)calloc(super_len, sizeof(char));
- if(H5LTdtype_to_text(super, stmp, &super_len)<0)
+ if(H5LTdtype_to_text(super, stmp, lang, &super_len)<0)
goto out;
strcat(*dt_str, stmp);
free(stmp);
@@ -2597,6 +2621,7 @@ next:
{
char *mname;
hid_t mtype;
+ size_t moffset;
H5T_class_t mclass;
size_t mlen;
char* mtmp;
@@ -2613,6 +2638,7 @@ next:
goto out;
if((mtype = H5Tget_member_type(dtype, i))<0)
goto out;
+ moffset = H5Tget_member_offset(dtype, i);
indentation(indent + COL, *dt_str);
if((mclass = H5Tget_class(mtype))<0)
@@ -2620,10 +2646,10 @@ next:
if (H5T_COMPOUND == mclass)
indent += COL;
- if(H5LTdtype_to_text(mtype, NULL, &mlen)<0)
+ if(H5LTdtype_to_text(mtype, NULL, lang, &mlen)<0)
goto out;
mtmp = (char*)calloc(mlen, sizeof(char));
- if(H5LTdtype_to_text(mtype, mtmp, &mlen)<0)
+ if(H5LTdtype_to_text(mtype, mtmp, lang, &mlen)<0)
goto out;
strcat(*dt_str, mtmp);
free(mtmp);
@@ -2631,9 +2657,12 @@ next:
if (H5T_COMPOUND == mclass)
indent -= COL;
- sprintf(tmp_str, " \"%s\";\n", mname);
+ sprintf(tmp_str, " \"%s\"", mname);
strcat(*dt_str, tmp_str);
free(mname);
+
+ sprintf(tmp_str, " : %d;\n", moffset);
+ strcat(*dt_str, tmp_str);
}
/* Print closing */
diff --git a/hl/src/H5LT.h b/hl/src/H5LT.h
index 3914f67..0024fcf 100644
--- a/hl/src/H5LT.h
+++ b/hl/src/H5LT.h
@@ -34,6 +34,13 @@
#define SKIPPED() {puts(" -SKIP-");fflush(stdout);}
#define EXAMPLE(WHAT) {printf("%-70s", "Example " WHAT); fflush(stdout);}
+typedef enum H5LT_lang_t {
+ H5LT_LANG_ERR = -1, /*this is the first*/
+ H5LT_DDL = 0, /*for DDL*/
+ H5LT_C = 1, /*for C*/
+ H5LT_FORTRAN = 2, /*for Fortran*/
+ H5LT_NO_LANG = 3 /*this is the last*/
+} H5LT_lang_t;
#ifdef __cplusplus
extern "C" {
@@ -344,8 +351,8 @@ H5_HLDLL herr_t H5LTget_attribute_info( hid_t loc_id,
H5_HLDLL hid_t H5LTcreate_compound_type( hsize_t nfields, size_t size, const char *field_names[],
const size_t *field_offset, const hid_t *field_types );
-H5_HLDLL hid_t H5LTtext_to_dtype(const char *text);
-H5_HLDLL herr_t H5LTdtype_to_text(hid_t dtype, char *str, size_t *len);
+H5_HLDLL hid_t H5LTtext_to_dtype(const char *text, H5LT_lang_t lang_type);
+H5_HLDLL herr_t H5LTdtype_to_text(hid_t dtype, char *str, H5LT_lang_t lang_type, size_t *len);
H5_HLDLL herr_t H5LTrepack( hsize_t nfields,
hsize_t nrecords,
@@ -388,7 +395,8 @@ H5_HLDLL herr_t H5LT_set_attribute_string( hid_t dset_id,
char *name,
char *buf );
-H5_HLDLL herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, size_t *slen, hbool_t no_user_buf);
+H5_HLDLL herr_t H5LT_dtype_to_text(hid_t dtype, char **dt_str, H5LT_lang_t lang,
+ size_t *slen, hbool_t no_user_buf);
#ifdef __cplusplus
}
diff --git a/hl/src/H5LTanalyze.c b/hl/src/H5LTanalyze.c
index 3f58e00..6f775bb 100644
--- a/hl/src/H5LTanalyze.c
+++ b/hl/src/H5LTanalyze.c
@@ -306,118 +306,122 @@ static void yy_fatal_error YY_PROTO(( yyconst char msg[] ));
*yy_cp = '\0'; \
yy_c_buf_p = yy_cp;
-#define YY_NUM_RULES 63
-#define YY_END_OF_BUFFER 64
-static yyconst short int yy_acclist[421] =
+#define YY_NUM_RULES 66
+#define YY_END_OF_BUFFER 67
+static yyconst short int yy_acclist[437] =
{ 0,
- 61, 61, 61, 61, 64, 63, 61, 63, 61, 62,
- 63, 54, 63, 53, 63, 60, 63, 63, 63, 63,
- 63, 58, 63, 59, 63, 56, 63, 57, 63, 55,
- 63, 55, 61, 63, 55, 61, 62, 63, 53, 55,
- 63, 55, 60, 63, 55, 63, 55, 63, 55, 63,
- 55, 63, 55, 58, 63, 55, 59, 63, 55, 56,
- 63, 55, 57, 63, 61, 53, 55, 55, 61, 53,
- 55, 55, 55, 55, 55, 55, 55, 55, 55, 55,
- 55, 38, 38, 55, 55, 55, 55, 55, 55, 39,
- 39, 55, 55, 55, 55, 55, 55, 55, 55, 55,
-
- 55, 55, 55, 55, 37, 55, 55, 55, 55, 55,
- 55, 55, 55, 55, 55, 55, 55, 55, 37, 55,
- 55, 36, 55, 55, 55, 55, 55, 55, 55, 55,
- 55, 55, 55, 55, 55, 55, 36, 55, 44, 48,
- 50, 52, 55, 55, 55, 44, 55, 48, 55, 55,
- 55, 55, 55, 55, 55, 55, 55, 50, 55, 52,
- 55, 49, 49, 55, 55, 55, 55, 55, 55, 55,
- 55, 55, 55, 55, 55, 55, 51, 35, 55, 55,
- 55, 55, 55, 51, 55, 55, 55, 55, 55, 55,
- 55, 55, 55, 35, 55, 55, 55, 55, 55, 55,
-
- 55, 55, 55, 55, 55, 55, 55, 55, 55, 55,
- 55, 55, 55, 55, 55, 55, 55, 47, 1, 2,
- 9, 10, 46, 47, 55, 55, 55, 55, 55, 55,
- 55, 55, 55, 55, 55, 55, 55, 55, 55, 55,
- 55, 55, 1, 55, 2, 55, 55, 55, 55, 55,
- 55, 55, 9, 55, 10, 55, 55, 55, 46, 55,
- 3, 4, 5, 6, 7, 8, 11, 12, 13, 14,
- 15, 16, 55, 55, 55, 55, 55, 55, 55, 55,
- 55, 55, 55, 55, 55, 55, 55, 55, 55, 55,
- 55, 3, 55, 4, 55, 5, 55, 6, 55, 7,
-
- 55, 8, 55, 11, 55, 12, 55, 13, 55, 14,
- 55, 15, 55, 16, 55, 55, 55, 55, 43, 45,
- 28, 29, 30, 31, 22, 43, 55, 45, 55, 28,
- 55, 29, 55, 30, 55, 31, 55, 55, 55, 55,
- 22, 55, 55, 55, 55, 55, 55, 55, 55, 55,
- 55, 55, 55, 55, 55, 17, 24, 23, 41, 17,
- 55, 55, 55, 55, 55, 24, 55, 55, 55, 55,
- 23, 55, 55, 55, 55, 41, 55, 55, 55, 32,
- 26, 18, 20, 19, 25, 40, 42, 55, 32, 55,
- 55, 26, 55, 18, 55, 20, 55, 19, 55, 55,
-
- 25, 55, 55, 40, 55, 42, 55, 33, 27, 21,
- 33, 55, 55, 27, 55, 21, 55, 34, 34, 55
+ 64, 64, 64, 64, 67, 66, 64, 66, 64, 65,
+ 66, 56, 66, 55, 66, 62, 66, 63, 66, 66,
+ 66, 66, 66, 60, 66, 61, 66, 58, 66, 59,
+ 66, 57, 66, 57, 64, 66, 57, 64, 65, 66,
+ 55, 57, 66, 57, 62, 66, 57, 63, 66, 57,
+ 66, 57, 66, 57, 66, 57, 66, 57, 60, 66,
+ 57, 61, 66, 57, 58, 66, 57, 59, 66, 64,
+ 55, 57, 57, 64, 55, 57, 57, 57, 57, 57,
+ 57, 57, 57, 57, 57, 57, 38, 38, 57, 57,
+ 57, 57, 57, 57, 39, 39, 57, 57, 57, 57,
+
+ 57, 57, 57, 57, 57, 57, 57, 57, 57, 57,
+ 37, 57, 57, 57, 57, 57, 57, 57, 57, 57,
+ 57, 57, 57, 57, 57, 37, 57, 57, 54, 36,
+ 57, 57, 57, 57, 57, 57, 57, 57, 57, 57,
+ 57, 57, 57, 57, 54, 57, 36, 57, 45, 49,
+ 51, 53, 57, 57, 57, 45, 57, 49, 57, 57,
+ 57, 57, 57, 57, 57, 57, 57, 51, 57, 53,
+ 57, 50, 50, 57, 57, 57, 57, 57, 57, 57,
+ 57, 57, 57, 57, 57, 57, 52, 35, 57, 57,
+ 57, 57, 57, 57, 52, 57, 57, 57, 57, 57,
+
+ 57, 57, 57, 57, 35, 57, 57, 57, 57, 57,
+ 57, 57, 57, 57, 57, 57, 57, 57, 57, 57,
+ 57, 57, 57, 57, 57, 57, 57, 57, 57, 48,
+ 1, 2, 9, 10, 47, 48, 57, 57, 57, 57,
+ 57, 57, 57, 57, 57, 57, 57, 57, 57, 57,
+ 57, 57, 57, 57, 57, 1, 57, 2, 57, 57,
+ 57, 57, 57, 57, 57, 9, 57, 10, 57, 57,
+ 57, 47, 57, 44, 3, 4, 5, 6, 7, 8,
+ 11, 12, 13, 14, 15, 16, 57, 44, 57, 57,
+ 57, 57, 57, 57, 57, 57, 57, 57, 57, 57,
+
+ 57, 57, 57, 57, 57, 57, 57, 3, 57, 4,
+ 57, 5, 57, 6, 57, 7, 57, 8, 57, 11,
+ 57, 12, 57, 13, 57, 14, 57, 15, 57, 16,
+ 57, 57, 57, 57, 43, 46, 28, 29, 30, 31,
+ 22, 43, 57, 46, 57, 28, 57, 29, 57, 30,
+ 57, 31, 57, 57, 57, 57, 22, 57, 57, 57,
+ 57, 57, 57, 57, 57, 57, 57, 57, 57, 57,
+ 57, 17, 24, 23, 41, 17, 57, 57, 57, 57,
+ 57, 24, 57, 57, 57, 57, 23, 57, 57, 57,
+ 57, 41, 57, 57, 57, 32, 26, 18, 20, 19,
+
+ 25, 40, 42, 57, 32, 57, 57, 26, 57, 18,
+ 57, 20, 57, 19, 57, 57, 25, 57, 57, 40,
+ 57, 42, 57, 33, 27, 21, 33, 57, 57, 27,
+ 57, 21, 57, 34, 34, 57
} ;
-static yyconst short int yy_accept[530] =
+static yyconst short int yy_accept[546] =
{ 0,
1, 2, 3, 4, 5, 6, 7, 9, 12, 14,
- 16, 18, 19, 20, 21, 22, 24, 26, 28, 30,
- 32, 35, 39, 42, 45, 47, 49, 51, 53, 56,
- 59, 62, 65, 66, 67, 67, 67, 67, 67, 67,
- 68, 70, 72, 73, 74, 75, 76, 77, 77, 77,
- 77, 77, 77, 78, 79, 80, 81, 82, 83, 83,
- 83, 83, 83, 83, 85, 86, 87, 88, 89, 90,
- 91, 91, 91, 91, 91, 91, 91, 91, 91, 91,
- 91, 91, 91, 93, 94, 95, 96, 97, 98, 99,
- 100, 101, 102, 103, 104, 105, 105, 105, 105, 105,
-
- 105, 105, 105, 105, 105, 105, 105, 105, 105, 106,
- 106, 107, 108, 109, 110, 111, 112, 113, 114, 115,
- 116, 117, 118, 119, 121, 122, 122, 122, 122, 122,
- 122, 122, 122, 122, 122, 122, 122, 122, 122, 122,
- 123, 124, 125, 126, 127, 128, 129, 130, 131, 132,
- 133, 134, 135, 136, 137, 139, 139, 139, 139, 140,
- 141, 141, 141, 141, 141, 141, 141, 141, 141, 142,
- 143, 144, 145, 146, 148, 150, 151, 152, 153, 154,
- 155, 156, 157, 158, 160, 162, 163, 163, 163, 163,
- 163, 163, 163, 163, 163, 163, 163, 163, 163, 165,
-
- 166, 167, 168, 169, 170, 171, 172, 173, 174, 175,
- 176, 177, 177, 177, 177, 177, 177, 178, 178, 178,
- 178, 178, 178, 178, 178, 178, 179, 179, 179, 179,
- 180, 181, 182, 183, 184, 186, 187, 188, 189, 190,
- 191, 192, 193, 194, 196, 197, 198, 199, 199, 199,
- 199, 199, 199, 199, 199, 199, 199, 199, 199, 199,
- 199, 199, 199, 199, 199, 199, 199, 200, 201, 202,
- 203, 204, 205, 206, 207, 208, 209, 210, 211, 212,
- 213, 214, 215, 216, 217, 218, 219, 219, 219, 219,
- 219, 219, 219, 219, 219, 219, 219, 219, 219, 219,
-
- 219, 219, 219, 219, 220, 221, 221, 221, 221, 221,
- 221, 221, 222, 223, 223, 223, 224, 226, 227, 228,
- 229, 230, 231, 232, 233, 234, 235, 236, 237, 238,
- 239, 240, 241, 242, 243, 245, 247, 248, 249, 250,
- 251, 252, 253, 255, 257, 258, 259, 261, 261, 261,
- 261, 261, 261, 261, 261, 261, 261, 261, 261, 261,
- 261, 261, 261, 261, 261, 261, 261, 262, 263, 264,
- 265, 266, 267, 268, 269, 270, 271, 272, 273, 273,
- 273, 273, 274, 275, 276, 277, 278, 279, 280, 281,
- 282, 283, 284, 285, 286, 287, 288, 289, 290, 291,
-
- 292, 294, 296, 298, 300, 302, 304, 306, 308, 310,
- 312, 314, 316, 317, 318, 319, 320, 321, 322, 323,
- 324, 325, 325, 325, 325, 326, 326, 326, 326, 326,
- 326, 326, 326, 326, 326, 326, 326, 326, 326, 328,
- 330, 332, 334, 336, 338, 339, 340, 341, 343, 344,
- 345, 346, 347, 348, 349, 350, 351, 352, 353, 354,
- 355, 356, 357, 357, 357, 357, 357, 358, 358, 358,
- 358, 359, 359, 359, 359, 360, 360, 360, 362, 363,
- 364, 365, 366, 368, 369, 370, 371, 373, 374, 375,
- 376, 378, 379, 380, 380, 381, 381, 382, 383, 384,
-
- 385, 385, 386, 386, 387, 388, 389, 391, 392, 394,
- 396, 398, 400, 401, 403, 404, 406, 408, 409, 409,
- 410, 411, 413, 414, 416, 418, 419, 421, 421
+ 16, 18, 20, 21, 22, 23, 24, 26, 28, 30,
+ 32, 34, 37, 41, 44, 47, 50, 52, 54, 56,
+ 58, 61, 64, 67, 70, 71, 72, 72, 72, 72,
+ 72, 72, 73, 75, 77, 78, 79, 80, 81, 82,
+ 82, 82, 82, 82, 82, 83, 84, 85, 86, 87,
+ 88, 88, 88, 88, 88, 88, 90, 91, 92, 93,
+ 94, 95, 96, 96, 96, 96, 96, 96, 96, 96,
+ 96, 96, 96, 96, 96, 96, 98, 99, 100, 101,
+ 102, 103, 104, 105, 106, 107, 108, 109, 110, 111,
+
+ 111, 111, 111, 111, 111, 111, 111, 111, 111, 111,
+ 111, 111, 111, 111, 112, 112, 113, 114, 115, 116,
+ 117, 118, 119, 120, 121, 122, 123, 124, 125, 126,
+ 128, 129, 129, 129, 129, 129, 129, 129, 129, 129,
+ 129, 129, 129, 129, 129, 129, 130, 131, 132, 133,
+ 134, 135, 136, 137, 138, 139, 140, 141, 142, 143,
+ 144, 145, 147, 149, 149, 149, 149, 150, 151, 151,
+ 151, 151, 151, 151, 151, 151, 151, 152, 153, 154,
+ 155, 156, 158, 160, 161, 162, 163, 164, 165, 166,
+ 167, 168, 170, 172, 173, 173, 173, 173, 173, 173,
+
+ 173, 173, 173, 173, 173, 173, 173, 175, 176, 177,
+ 178, 179, 180, 181, 182, 183, 184, 185, 186, 187,
+ 187, 187, 187, 187, 187, 187, 188, 188, 188, 188,
+ 188, 188, 188, 188, 188, 189, 189, 189, 189, 190,
+ 191, 192, 193, 194, 195, 197, 198, 199, 200, 201,
+ 202, 203, 204, 205, 207, 208, 209, 210, 210, 210,
+ 210, 210, 210, 210, 210, 210, 210, 210, 210, 210,
+ 210, 210, 210, 210, 210, 210, 210, 210, 211, 212,
+ 213, 214, 215, 216, 217, 218, 219, 220, 221, 222,
+ 223, 224, 225, 226, 227, 228, 229, 230, 231, 231,
+
+ 231, 231, 231, 231, 231, 231, 231, 231, 231, 231,
+ 231, 231, 231, 231, 231, 231, 231, 232, 233, 233,
+ 233, 233, 233, 233, 233, 234, 235, 235, 235, 236,
+ 238, 239, 240, 241, 242, 243, 244, 245, 246, 247,
+ 248, 249, 250, 251, 252, 253, 254, 255, 256, 258,
+ 260, 261, 262, 263, 264, 265, 266, 268, 270, 271,
+ 272, 274, 274, 275, 275, 275, 275, 275, 275, 275,
+ 275, 275, 275, 275, 275, 275, 275, 275, 275, 275,
+ 275, 275, 276, 277, 278, 279, 280, 281, 282, 283,
+ 284, 285, 286, 287, 287, 287, 287, 288, 290, 291,
+
+ 292, 293, 294, 295, 296, 297, 298, 299, 300, 301,
+ 302, 303, 304, 305, 306, 307, 308, 310, 312, 314,
+ 316, 318, 320, 322, 324, 326, 328, 330, 332, 333,
+ 334, 335, 336, 337, 338, 339, 340, 341, 341, 341,
+ 341, 342, 342, 342, 342, 342, 342, 342, 342, 342,
+ 342, 342, 342, 342, 342, 344, 346, 348, 350, 352,
+ 354, 355, 356, 357, 359, 360, 361, 362, 363, 364,
+ 365, 366, 367, 368, 369, 370, 371, 372, 373, 373,
+ 373, 373, 373, 374, 374, 374, 374, 375, 375, 375,
+ 375, 376, 376, 376, 378, 379, 380, 381, 382, 384,
+
+ 385, 386, 387, 389, 390, 391, 392, 394, 395, 396,
+ 396, 397, 397, 398, 399, 400, 401, 401, 402, 402,
+ 403, 404, 405, 407, 408, 410, 412, 414, 416, 417,
+ 419, 420, 422, 424, 425, 425, 426, 427, 429, 430,
+ 432, 434, 435, 437, 437
} ;
static yyconst int yy_ec[256] =
@@ -427,15 +431,15 @@ static yyconst int yy_ec[256] =
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 2, 1, 4, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 5, 6, 7,
- 8, 9, 10, 11, 5, 12, 5, 1, 13, 1,
- 1, 1, 1, 1, 14, 15, 16, 17, 18, 19,
- 20, 21, 22, 1, 1, 23, 24, 25, 26, 27,
- 28, 29, 30, 31, 32, 33, 1, 1, 34, 35,
- 36, 1, 37, 1, 38, 1, 1, 1, 1, 1,
+ 8, 9, 10, 11, 5, 12, 5, 13, 14, 1,
+ 1, 1, 1, 1, 15, 16, 17, 18, 19, 20,
+ 21, 22, 23, 1, 1, 24, 25, 26, 27, 28,
+ 29, 30, 31, 32, 33, 34, 1, 1, 35, 36,
+ 37, 1, 38, 1, 39, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 39, 1, 40, 1, 1, 1, 1, 1,
+ 1, 1, 40, 1, 41, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
@@ -452,284 +456,293 @@ static yyconst int yy_ec[256] =
1, 1, 1, 1, 1
} ;
-static yyconst int yy_meta[41] =
+static yyconst int yy_meta[42] =
{ 0,
1, 1, 1, 2, 3, 3, 3, 3, 3, 3,
3, 3, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
- 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
+ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1
} ;
-static yyconst short int yy_base[531] =
+static yyconst short int yy_base[547] =
{ 0,
- 0, 0, 40, 0, 594, 595, 79, 81, 595, 0,
- 595, 55, 583, 565, 560, 595, 595, 595, 595, 0,
- 85, 87, 86, 0, 69, 580, 562, 557, 0, 0,
- 0, 0, 99, 0, 569, 552, 554, 556, 554, 0,
- 101, 0, 564, 547, 549, 551, 549, 546, 549, 537,
- 536, 78, 542, 545, 533, 532, 79, 595, 551, 96,
- 538, 553, 544, 0, 547, 116, 534, 549, 540, 595,
- 532, 81, 535, 533, 540, 543, 529, 524, 102, 532,
- 536, 517, 0, 522, 98, 525, 523, 530, 533, 519,
- 514, 117, 522, 526, 507, 512, 516, 521, 508, 505,
-
- 507, 517, 503, 519, 110, 503, 513, 495, 595, 511,
- 499, 503, 508, 495, 492, 494, 504, 490, 506, 116,
- 490, 500, 482, 0, 498, 501, 487, 482, 506, 487,
- 479, 491, 486, 479, 468, 115, 483, 479, 485, 595,
- 488, 474, 469, 493, 474, 466, 478, 473, 466, 455,
- 121, 470, 466, 472, 0, 455, 462, 449, 595, 595,
- 457, 447, 451, 451, 91, 457, 122, 467, 595, 595,
- 446, 453, 440, 0, 0, 448, 438, 442, 442, 122,
- 448, 125, 458, 0, 0, 595, 439, 456, 455, 449,
- 449, 448, 150, 157, 445, 432, 436, 447, 0, 429,
-
- 446, 445, 439, 439, 438, 164, 171, 435, 422, 426,
- 437, 426, 420, 424, 109, 410, 595, 436, 439, 436,
- 151, 433, 436, 433, 158, 595, 418, 426, 416, 413,
- 407, 411, 140, 397, 0, 423, 426, 423, 163, 420,
- 423, 420, 165, 0, 405, 413, 403, 408, 408, 385,
- 415, 412, 173, 170, 176, 179, 402, 401, 183, 185,
- 186, 400, 399, 393, 399, 396, 396, 396, 373, 403,
- 400, 194, 189, 192, 199, 390, 389, 204, 205, 206,
- 388, 387, 381, 387, 384, 595, 379, 370, 208, 210,
- 378, 372, 374, 371, 213, 216, 218, 377, 376, 375,
-
- 374, 373, 372, 595, 595, 371, 370, 369, 368, 367,
- 366, 595, 595, 133, 365, 595, 0, 360, 351, 220,
- 223, 359, 353, 355, 352, 227, 226, 229, 358, 357,
- 356, 355, 354, 353, 0, 0, 352, 351, 350, 349,
- 348, 347, 0, 0, 140, 346, 0, 341, 356, 343,
- 342, 341, 340, 343, 324, 329, 323, 327, 326, 326,
- 329, 323, 327, 322, 161, 325, 595, 595, 595, 595,
- 595, 595, 595, 595, 595, 595, 595, 595, 331, 326,
- 316, 320, 335, 322, 321, 320, 319, 322, 303, 308,
- 302, 306, 305, 305, 308, 302, 306, 301, 231, 304,
-
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 310, 305, 295, 595, 595, 595, 595, 595,
- 595, 292, 305, 305, 595, 286, 292, 296, 301, 285,
- 299, 281, 285, 285, 283, 291, 278, 292, 0, 0,
- 0, 0, 0, 0, 276, 289, 289, 0, 270, 276,
- 280, 285, 269, 283, 265, 269, 269, 267, 275, 262,
- 276, 595, 266, 257, 272, 266, 595, 256, 253, 254,
- 595, 257, 261, 251, 595, 255, 261, 0, 254, 245,
- 260, 254, 0, 244, 241, 242, 0, 245, 249, 239,
- 0, 243, 249, 247, 595, 241, 595, 595, 595, 595,
-
- 243, 595, 230, 595, 595, 240, 0, 233, 0, 0,
- 0, 0, 235, 0, 218, 0, 0, 595, 200, 595,
- 595, 0, 179, 0, 0, 595, 0, 595, 154, 259
+ 0, 0, 41, 0, 610, 611, 81, 83, 611, 0,
+ 611, 611, 56, 599, 580, 575, 611, 611, 611, 611,
+ 0, 87, 89, 88, 0, 0, 70, 596, 577, 572,
+ 0, 0, 0, 0, 101, 0, 584, 567, 569, 571,
+ 569, 0, 103, 0, 579, 562, 564, 566, 564, 561,
+ 564, 552, 551, 79, 557, 560, 548, 547, 80, 611,
+ 566, 97, 87, 569, 560, 0, 563, 117, 90, 566,
+ 557, 611, 549, 99, 552, 550, 557, 560, 546, 541,
+ 118, 549, 556, 552, 533, 0, 538, 108, 541, 539,
+ 546, 549, 535, 530, 126, 538, 545, 541, 522, 527,
+
+ 531, 536, 523, 520, 522, 532, 518, 534, 95, 518,
+ 528, 510, 524, 611, 525, 513, 517, 522, 509, 506,
+ 508, 518, 504, 520, 97, 504, 514, 496, 510, 0,
+ 511, 514, 500, 495, 520, 500, 492, 504, 499, 492,
+ 481, 106, 496, 492, 498, 611, 611, 501, 487, 482,
+ 507, 487, 479, 491, 486, 479, 468, 123, 483, 479,
+ 485, 0, 0, 468, 475, 462, 611, 611, 470, 460,
+ 464, 464, 126, 470, 126, 480, 611, 611, 459, 466,
+ 453, 0, 0, 461, 451, 455, 455, 130, 461, 129,
+ 471, 0, 0, 611, 452, 139, 469, 463, 463, 462,
+
+ 158, 165, 459, 446, 450, 461, 0, 443, 141, 460,
+ 454, 454, 453, 172, 179, 450, 437, 441, 452, 441,
+ 435, 433, 438, 150, 424, 611, 451, 454, 451, 151,
+ 448, 451, 448, 165, 611, 432, 440, 430, 427, 421,
+ 419, 424, 157, 410, 0, 437, 440, 437, 170, 434,
+ 437, 434, 172, 0, 418, 426, 416, 421, 421, 417,
+ 397, 428, 425, 180, 177, 183, 186, 414, 413, 190,
+ 192, 193, 412, 411, 405, 411, 408, 408, 408, 404,
+ 384, 415, 412, 201, 196, 199, 206, 401, 400, 211,
+ 212, 213, 399, 398, 392, 398, 395, 611, 390, 400,
+
+ 380, 215, 217, 388, 382, 384, 381, 220, 223, 225,
+ 387, 386, 385, 384, 383, 382, 611, 611, 381, 380,
+ 379, 378, 377, 376, 611, 611, 218, 375, 611, 0,
+ 370, 380, 360, 227, 236, 368, 362, 364, 361, 235,
+ 241, 244, 367, 366, 365, 364, 363, 362, 0, 0,
+ 361, 360, 359, 358, 357, 356, 0, 0, 237, 355,
+ 0, 350, 611, 366, 352, 351, 350, 349, 352, 333,
+ 338, 332, 336, 335, 335, 338, 332, 336, 331, 155,
+ 334, 611, 611, 611, 611, 611, 611, 611, 611, 611,
+ 611, 611, 611, 340, 335, 325, 329, 0, 345, 331,
+
+ 330, 329, 328, 331, 312, 317, 311, 315, 314, 314,
+ 317, 311, 315, 310, 168, 313, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 319, 314,
+ 304, 611, 611, 611, 611, 611, 611, 301, 314, 314,
+ 611, 295, 301, 305, 310, 294, 308, 290, 294, 294,
+ 292, 300, 287, 301, 0, 0, 0, 0, 0, 0,
+ 285, 298, 298, 0, 279, 285, 289, 294, 278, 292,
+ 274, 278, 278, 276, 284, 271, 285, 611, 275, 266,
+ 281, 275, 611, 265, 262, 263, 611, 266, 270, 260,
+ 611, 264, 270, 0, 263, 254, 269, 263, 0, 253,
+
+ 250, 251, 0, 254, 258, 247, 0, 249, 255, 253,
+ 611, 247, 611, 611, 611, 611, 249, 611, 234, 611,
+ 611, 245, 0, 233, 0, 0, 0, 0, 234, 0,
+ 222, 0, 0, 611, 207, 611, 611, 0, 186, 0,
+ 0, 611, 0, 611, 106, 275
} ;
-static yyconst short int yy_def[531] =
+static yyconst short int yy_def[547] =
{ 0,
- 528, 1, 528, 3, 528, 528, 528, 528, 528, 529,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 530,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 528, 529, 528, 528, 528, 528, 528, 530,
- 530, 23, 530, 530, 530, 530, 530, 528, 528, 528,
- 528, 528, 530, 530, 530, 530, 530, 528, 528, 528,
- 528, 528, 528, 530, 530, 530, 530, 530, 530, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 528, 528, 528, 528, 528,
-
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 530, 530,
-
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 530,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 530, 530, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
-
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 530, 530, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
-
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 530, 530,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 530, 530, 530,
- 530, 530, 530, 530, 530, 530, 530, 530, 530, 530,
- 530, 530, 530, 528, 528, 528, 528, 528, 528, 528,
-
- 528, 528, 528, 528, 528, 530, 530, 530, 530, 530,
- 530, 530, 530, 530, 530, 530, 530, 528, 528, 528,
- 528, 530, 530, 530, 530, 528, 530, 0, 528, 528
+ 544, 1, 544, 3, 544, 544, 544, 544, 544, 545,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 544, 545, 544, 544, 544, 544,
+ 544, 546, 546, 24, 546, 546, 546, 546, 546, 544,
+ 544, 544, 544, 544, 546, 546, 546, 546, 546, 544,
+ 544, 544, 544, 544, 544, 546, 546, 546, 546, 546,
+ 546, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 544,
+
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 544, 544, 544, 544, 544, 544, 544,
+
+ 544, 544, 544, 544, 544, 544, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 544, 544, 544,
+
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 546, 546, 546, 546,
+
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 546, 546, 546, 546, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 546, 546, 546, 546, 546, 546, 546,
+
+ 546, 546, 546, 546, 546, 546, 546, 546, 546, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 546, 546, 546, 546, 546, 546, 546, 546, 546,
+ 546, 546, 546, 544, 544, 544, 544, 546, 546, 546,
+ 546, 544, 546, 0, 544, 544
} ;
-static yyconst short int yy_nxt[636] =
+static yyconst short int yy_nxt[653] =
{ 0,
6, 7, 8, 9, 10, 10, 10, 10, 10, 10,
- 10, 10, 11, 6, 6, 12, 6, 6, 6, 6,
- 13, 6, 6, 6, 6, 14, 6, 6, 6, 15,
- 6, 6, 6, 6, 6, 16, 17, 6, 18, 19,
- 20, 21, 22, 9, 23, 23, 23, 23, 23, 23,
- 23, 23, 24, 20, 20, 25, 20, 20, 20, 20,
- 26, 20, 20, 20, 20, 27, 20, 20, 20, 28,
- 20, 20, 20, 20, 20, 29, 30, 20, 31, 32,
- 33, 33, 33, 33, 35, 36, 41, 41, 41, 41,
- 42, 42, 42, 42, 42, 42, 42, 42, 43, 44,
-
- 33, 33, 41, 41, 62, 68, 97, 63, 69, 71,
- 98, 72, 193, 73, 74, 106, 251, 75, 99, 252,
- 76, 77, 194, 112, 107, 78, 135, 113, 79, 84,
- 121, 85, 150, 86, 87, 114, 166, 88, 136, 122,
- 89, 90, 181, 206, 151, 91, 196, 270, 92, 209,
- 271, 197, 167, 207, 210, 218, 34, 219, 182, 379,
- 220, 221, 222, 380, 223, 257, 413, 224, 225, 236,
- 414, 237, 262, 258, 238, 239, 240, 276, 241, 281,
- 263, 242, 243, 433, 298, 277, 434, 282, 291, 292,
- 300, 293, 299, 302, 294, 295, 527, 306, 301, 308,
-
- 310, 303, 296, 329, 297, 307, 331, 309, 311, 322,
- 323, 330, 324, 333, 332, 325, 326, 526, 337, 339,
- 341, 334, 350, 327, 352, 328, 338, 340, 342, 358,
- 351, 361, 353, 363, 384, 359, 362, 386, 360, 364,
- 365, 395, 385, 392, 397, 387, 396, 366, 525, 393,
- 398, 399, 394, 456, 524, 523, 457, 522, 400, 40,
- 521, 40, 520, 519, 518, 517, 516, 515, 514, 513,
- 512, 511, 510, 509, 508, 507, 506, 505, 504, 503,
- 502, 501, 500, 499, 498, 497, 496, 495, 494, 493,
- 492, 491, 490, 489, 488, 487, 486, 485, 484, 483,
-
- 482, 481, 480, 479, 478, 477, 476, 475, 474, 473,
- 472, 471, 470, 469, 468, 467, 466, 465, 464, 463,
- 462, 461, 460, 459, 458, 455, 454, 453, 452, 451,
- 450, 449, 448, 447, 446, 445, 444, 443, 442, 441,
- 440, 439, 438, 437, 436, 435, 432, 431, 430, 429,
- 428, 427, 426, 425, 424, 423, 422, 421, 420, 419,
- 418, 417, 416, 415, 412, 411, 410, 409, 408, 407,
- 406, 405, 404, 403, 402, 401, 391, 390, 389, 388,
- 383, 382, 381, 378, 377, 376, 375, 374, 373, 372,
- 371, 370, 369, 368, 367, 357, 356, 355, 354, 349,
-
- 348, 347, 346, 345, 344, 343, 336, 335, 321, 320,
- 319, 318, 317, 316, 315, 314, 313, 312, 305, 304,
- 290, 289, 288, 287, 286, 285, 284, 283, 280, 279,
- 278, 275, 274, 273, 272, 269, 268, 267, 266, 265,
- 264, 261, 260, 259, 256, 255, 254, 253, 250, 249,
- 248, 247, 246, 245, 244, 235, 234, 233, 232, 231,
- 230, 229, 228, 227, 226, 217, 216, 215, 214, 213,
- 212, 211, 208, 205, 204, 203, 202, 201, 200, 199,
- 198, 195, 192, 191, 190, 189, 188, 187, 186, 185,
- 184, 183, 180, 179, 178, 177, 176, 175, 174, 173,
-
- 172, 171, 170, 169, 168, 165, 164, 163, 162, 161,
- 160, 159, 158, 157, 156, 155, 154, 153, 152, 149,
- 148, 147, 146, 145, 144, 143, 142, 141, 140, 139,
- 138, 137, 134, 133, 132, 131, 130, 129, 128, 127,
- 126, 125, 124, 123, 120, 119, 118, 117, 116, 115,
- 111, 110, 109, 108, 105, 104, 103, 102, 101, 100,
- 96, 95, 94, 93, 83, 82, 81, 80, 70, 67,
- 66, 65, 64, 61, 60, 59, 58, 57, 56, 55,
- 54, 53, 52, 51, 50, 49, 48, 47, 46, 45,
- 39, 38, 37, 528, 5, 528, 528, 528, 528, 528,
-
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528
+ 10, 10, 11, 12, 6, 6, 13, 6, 6, 6,
+ 6, 14, 6, 6, 6, 6, 15, 6, 6, 6,
+ 16, 6, 6, 6, 6, 6, 17, 18, 6, 19,
+ 20, 21, 22, 23, 9, 24, 24, 24, 24, 24,
+ 24, 24, 24, 25, 26, 21, 21, 27, 21, 21,
+ 21, 21, 28, 21, 21, 21, 21, 29, 21, 21,
+ 21, 30, 21, 21, 21, 21, 21, 31, 32, 21,
+ 33, 34, 35, 35, 35, 35, 37, 38, 43, 43,
+ 43, 43, 44, 44, 44, 44, 44, 44, 44, 44,
+
+ 45, 46, 35, 35, 43, 43, 64, 70, 36, 65,
+ 71, 73, 141, 74, 157, 75, 76, 82, 83, 77,
+ 96, 97, 78, 79, 142, 101, 158, 80, 174, 102,
+ 81, 87, 110, 88, 117, 89, 90, 103, 118, 91,
+ 126, 111, 92, 93, 175, 189, 119, 94, 201, 127,
+ 95, 204, 214, 221, 217, 240, 205, 262, 202, 218,
+ 263, 190, 215, 227, 282, 228, 268, 283, 229, 230,
+ 231, 222, 232, 241, 269, 233, 234, 246, 449, 247,
+ 273, 450, 248, 249, 250, 288, 251, 293, 274, 252,
+ 253, 472, 311, 289, 473, 294, 304, 305, 313, 306,
+
+ 312, 315, 307, 308, 543, 319, 314, 321, 323, 316,
+ 309, 343, 310, 320, 345, 322, 324, 336, 337, 344,
+ 338, 347, 346, 339, 340, 542, 351, 353, 355, 348,
+ 365, 341, 367, 342, 352, 354, 356, 373, 366, 376,
+ 368, 378, 400, 374, 377, 394, 375, 379, 380, 395,
+ 401, 402, 408, 541, 540, 381, 539, 411, 409, 403,
+ 413, 410, 412, 538, 429, 537, 414, 415, 430, 536,
+ 535, 534, 533, 532, 416, 42, 531, 42, 530, 529,
+ 528, 527, 526, 525, 524, 523, 522, 521, 520, 519,
+ 518, 517, 516, 515, 514, 513, 512, 511, 510, 509,
+
+ 508, 507, 506, 505, 504, 503, 502, 501, 500, 499,
+ 498, 497, 496, 495, 494, 493, 492, 491, 490, 489,
+ 488, 487, 486, 485, 484, 483, 482, 481, 480, 479,
+ 478, 477, 476, 475, 474, 471, 470, 469, 468, 467,
+ 466, 465, 464, 463, 462, 461, 460, 459, 458, 457,
+ 456, 455, 454, 453, 452, 451, 448, 447, 446, 445,
+ 444, 443, 442, 441, 440, 439, 438, 437, 436, 435,
+ 434, 433, 432, 431, 428, 427, 426, 425, 424, 423,
+ 422, 421, 420, 419, 418, 417, 407, 406, 405, 404,
+ 399, 398, 397, 396, 393, 392, 391, 390, 389, 388,
+
+ 387, 386, 385, 384, 383, 382, 372, 371, 370, 369,
+ 364, 363, 362, 361, 360, 359, 358, 357, 350, 349,
+ 335, 334, 333, 332, 331, 330, 329, 328, 327, 326,
+ 325, 318, 317, 303, 302, 301, 300, 299, 298, 297,
+ 296, 295, 292, 291, 290, 287, 286, 285, 284, 281,
+ 280, 279, 278, 277, 276, 275, 272, 271, 270, 267,
+ 266, 265, 264, 261, 260, 259, 258, 257, 256, 255,
+ 254, 245, 244, 243, 242, 239, 238, 237, 236, 235,
+ 226, 225, 224, 223, 220, 219, 216, 213, 212, 211,
+ 210, 209, 208, 207, 206, 203, 200, 199, 198, 197,
+
+ 196, 195, 194, 193, 192, 191, 188, 187, 186, 185,
+ 184, 183, 182, 181, 180, 179, 178, 177, 176, 173,
+ 172, 171, 170, 169, 168, 167, 166, 165, 164, 163,
+ 162, 161, 160, 159, 156, 155, 154, 153, 152, 151,
+ 150, 149, 148, 147, 146, 145, 144, 143, 140, 139,
+ 138, 137, 136, 135, 134, 133, 132, 131, 130, 129,
+ 128, 125, 124, 123, 122, 121, 120, 116, 115, 114,
+ 113, 112, 109, 108, 107, 106, 105, 104, 100, 99,
+ 98, 86, 85, 84, 72, 69, 68, 67, 66, 63,
+ 62, 61, 60, 59, 58, 57, 56, 55, 54, 53,
+
+ 52, 51, 50, 49, 48, 47, 41, 40, 39, 544,
+ 5, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544
} ;
-static yyconst short int yy_chk[636] =
+static yyconst short int yy_chk[653] =
{ 0,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
+ 1, 3, 3, 3, 3, 3, 3, 3, 3, 3,
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 3, 3, 3, 3, 3, 3, 3, 3, 3, 3,
- 7, 7, 8, 8, 12, 12, 21, 21, 22, 22,
- 23, 23, 23, 23, 23, 23, 23, 23, 25, 25,
-
- 33, 33, 41, 41, 52, 57, 72, 52, 57, 60,
- 72, 60, 165, 60, 60, 79, 215, 60, 72, 215,
- 60, 60, 165, 85, 79, 60, 105, 85, 60, 66,
- 92, 66, 120, 66, 66, 85, 136, 66, 105, 92,
- 66, 66, 151, 180, 120, 66, 167, 233, 66, 182,
- 233, 167, 136, 180, 182, 193, 529, 193, 151, 314,
- 193, 193, 194, 314, 194, 221, 345, 194, 194, 206,
- 345, 206, 225, 221, 206, 206, 207, 239, 207, 243,
- 225, 207, 207, 365, 254, 239, 365, 243, 253, 253,
- 255, 253, 254, 256, 253, 253, 523, 259, 255, 260,
-
- 261, 256, 253, 273, 253, 259, 274, 260, 261, 272,
- 272, 273, 272, 275, 274, 272, 272, 519, 278, 279,
- 280, 275, 289, 272, 290, 272, 278, 279, 280, 295,
- 289, 296, 290, 297, 320, 295, 296, 321, 295, 297,
- 297, 327, 320, 326, 328, 321, 327, 297, 515, 326,
- 328, 328, 326, 399, 513, 508, 399, 506, 328, 530,
- 503, 530, 501, 496, 494, 493, 492, 490, 489, 488,
- 486, 485, 484, 482, 481, 480, 479, 477, 476, 474,
- 473, 472, 470, 469, 468, 466, 465, 464, 463, 461,
- 460, 459, 458, 457, 456, 455, 454, 453, 452, 451,
-
- 450, 449, 447, 446, 445, 438, 437, 436, 435, 434,
- 433, 432, 431, 430, 429, 428, 427, 426, 424, 423,
- 422, 415, 414, 413, 400, 398, 397, 396, 395, 394,
- 393, 392, 391, 390, 389, 388, 387, 386, 385, 384,
- 383, 382, 381, 380, 379, 366, 364, 363, 362, 361,
- 360, 359, 358, 357, 356, 355, 354, 353, 352, 351,
- 350, 349, 348, 346, 342, 341, 340, 339, 338, 337,
- 334, 333, 332, 331, 330, 329, 325, 324, 323, 322,
- 319, 318, 315, 311, 310, 309, 308, 307, 306, 303,
- 302, 301, 300, 299, 298, 294, 293, 292, 291, 288,
-
- 287, 285, 284, 283, 282, 281, 277, 276, 271, 270,
- 269, 268, 267, 266, 265, 264, 263, 262, 258, 257,
- 252, 251, 250, 249, 248, 247, 246, 245, 242, 241,
- 240, 238, 237, 236, 234, 232, 231, 230, 229, 228,
- 227, 224, 223, 222, 220, 219, 218, 216, 214, 213,
- 212, 211, 210, 209, 208, 205, 204, 203, 202, 201,
- 200, 198, 197, 196, 195, 192, 191, 190, 189, 188,
- 187, 183, 181, 179, 178, 177, 176, 173, 172, 171,
- 168, 166, 164, 163, 162, 161, 158, 157, 156, 154,
- 153, 152, 150, 149, 148, 147, 146, 145, 144, 143,
-
- 142, 141, 139, 138, 137, 135, 134, 133, 132, 131,
- 130, 129, 128, 127, 126, 125, 123, 122, 121, 119,
- 118, 117, 116, 115, 114, 113, 112, 111, 110, 108,
- 107, 106, 104, 103, 102, 101, 100, 99, 98, 97,
- 96, 95, 94, 93, 91, 90, 89, 88, 87, 86,
- 84, 82, 81, 80, 78, 77, 76, 75, 74, 73,
- 71, 69, 68, 67, 65, 63, 62, 61, 59, 56,
- 55, 54, 53, 51, 50, 49, 48, 47, 46, 45,
- 44, 43, 39, 38, 37, 36, 35, 28, 27, 26,
- 15, 14, 13, 5, 528, 528, 528, 528, 528, 528,
-
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528, 528, 528, 528, 528, 528,
- 528, 528, 528, 528, 528
+ 3, 3, 7, 7, 8, 8, 13, 13, 22, 22,
+ 23, 23, 24, 24, 24, 24, 24, 24, 24, 24,
+
+ 27, 27, 35, 35, 43, 43, 54, 59, 545, 54,
+ 59, 62, 109, 62, 125, 62, 62, 63, 63, 62,
+ 69, 69, 62, 62, 109, 74, 125, 62, 142, 74,
+ 62, 68, 81, 68, 88, 68, 68, 74, 88, 68,
+ 95, 81, 68, 68, 142, 158, 88, 68, 173, 95,
+ 68, 175, 188, 196, 190, 209, 175, 224, 173, 190,
+ 224, 158, 188, 201, 243, 201, 230, 243, 201, 201,
+ 202, 196, 202, 209, 230, 202, 202, 214, 380, 214,
+ 234, 380, 214, 214, 215, 249, 215, 253, 234, 215,
+ 215, 415, 265, 249, 415, 253, 264, 264, 266, 264,
+
+ 265, 267, 264, 264, 539, 270, 266, 271, 272, 267,
+ 264, 285, 264, 270, 286, 271, 272, 284, 284, 285,
+ 284, 287, 286, 284, 284, 535, 290, 291, 292, 287,
+ 302, 284, 303, 284, 290, 291, 292, 308, 302, 309,
+ 303, 310, 334, 308, 309, 327, 308, 310, 310, 327,
+ 334, 335, 340, 531, 529, 310, 524, 341, 340, 335,
+ 342, 340, 341, 522, 359, 519, 342, 342, 359, 517,
+ 512, 510, 509, 508, 342, 546, 506, 546, 505, 504,
+ 502, 501, 500, 498, 497, 496, 495, 493, 492, 490,
+ 489, 488, 486, 485, 484, 482, 481, 480, 479, 477,
+
+ 476, 475, 474, 473, 472, 471, 470, 469, 468, 467,
+ 466, 465, 463, 462, 461, 454, 453, 452, 451, 450,
+ 449, 448, 447, 446, 445, 444, 443, 442, 440, 439,
+ 438, 431, 430, 429, 416, 414, 413, 412, 411, 410,
+ 409, 408, 407, 406, 405, 404, 403, 402, 401, 400,
+ 399, 397, 396, 395, 394, 381, 379, 378, 377, 376,
+ 375, 374, 373, 372, 371, 370, 369, 368, 367, 366,
+ 365, 364, 362, 360, 356, 355, 354, 353, 352, 351,
+ 348, 347, 346, 345, 344, 343, 339, 338, 337, 336,
+ 333, 332, 331, 328, 324, 323, 322, 321, 320, 319,
+
+ 316, 315, 314, 313, 312, 311, 307, 306, 305, 304,
+ 301, 300, 299, 297, 296, 295, 294, 293, 289, 288,
+ 283, 282, 281, 280, 279, 278, 277, 276, 275, 274,
+ 273, 269, 268, 263, 262, 261, 260, 259, 258, 257,
+ 256, 255, 252, 251, 250, 248, 247, 246, 244, 242,
+ 241, 240, 239, 238, 237, 236, 233, 232, 231, 229,
+ 228, 227, 225, 223, 222, 221, 220, 219, 218, 217,
+ 216, 213, 212, 211, 210, 208, 206, 205, 204, 203,
+ 200, 199, 198, 197, 195, 191, 189, 187, 186, 185,
+ 184, 181, 180, 179, 176, 174, 172, 171, 170, 169,
+
+ 166, 165, 164, 161, 160, 159, 157, 156, 155, 154,
+ 153, 152, 151, 150, 149, 148, 145, 144, 143, 141,
+ 140, 139, 138, 137, 136, 135, 134, 133, 132, 131,
+ 129, 128, 127, 126, 124, 123, 122, 121, 120, 119,
+ 118, 117, 116, 115, 113, 112, 111, 110, 108, 107,
+ 106, 105, 104, 103, 102, 101, 100, 99, 98, 97,
+ 96, 94, 93, 92, 91, 90, 89, 87, 85, 84,
+ 83, 82, 80, 79, 78, 77, 76, 75, 73, 71,
+ 70, 67, 65, 64, 61, 58, 57, 56, 55, 53,
+ 52, 51, 50, 49, 48, 47, 46, 45, 41, 40,
+
+ 39, 38, 37, 30, 29, 28, 16, 15, 14, 5,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544, 544, 544, 544, 544, 544, 544, 544, 544,
+ 544, 544
} ;
static yy_state_type yy_state_buf[YY_BUF_SIZE + 2], *yy_state_ptr;
@@ -787,10 +800,10 @@ extern hbool_t is_enum_memb;
/*variables for string type*/
extern hbool_t is_str_size;
-extern hbool_t is_str_pad;
/*variables for opaque type*/
extern hbool_t is_opq_size;
+extern hbool_t is_opq_tag;
hbool_t first_quote = 1;
@@ -800,7 +813,7 @@ char *myinput;*/
#define TAG_STRING 1
-#line 783 "H5LTanalyze.c"
+#line 796 "H5LTanalyze.c"
/* Macros after this point can all be overridden by user definitions in
* section 1.
@@ -954,7 +967,7 @@ YY_DECL
#line 55 "H5LTanalyze.l"
-#line 937 "H5LTanalyze.c"
+#line 950 "H5LTanalyze.c"
if ( yy_init )
{
@@ -1002,14 +1015,14 @@ yy_match:
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
{
yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 529 )
+ if ( yy_current_state >= 545 )
yy_c = yy_meta[(unsigned int) yy_c];
}
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
*yy_state_ptr++ = yy_current_state;
++yy_cp;
}
- while ( yy_base[yy_current_state] != 595 );
+ while ( yy_base[yy_current_state] != 611 );
yy_find_action:
yy_current_state = *--yy_state_ptr;
@@ -1256,66 +1269,78 @@ YY_RULE_SETUP
case 44:
YY_RULE_SETUP
#line 104 "H5LTanalyze.l"
-{return token(H5T_C_S1_TOKEN);}
+{return token(H5T_CSET_UTF8_TOKEN);}
YY_BREAK
case 45:
YY_RULE_SETUP
#line 105 "H5LTanalyze.l"
-{return token(H5T_FORTRAN_S1_TOKEN);}
+{return token(H5T_C_S1_TOKEN);}
YY_BREAK
case 46:
YY_RULE_SETUP
#line 106 "H5LTanalyze.l"
-{return token(H5T_VARIABLE_TOKEN);}
+{return token(H5T_FORTRAN_S1_TOKEN);}
YY_BREAK
case 47:
YY_RULE_SETUP
-#line 108 "H5LTanalyze.l"
-{return token(H5T_COMPOUND_TOKEN);}
+#line 107 "H5LTanalyze.l"
+{return token(H5T_VARIABLE_TOKEN);}
YY_BREAK
case 48:
YY_RULE_SETUP
#line 109 "H5LTanalyze.l"
-{return token(H5T_ENUM_TOKEN);}
+{return token(H5T_COMPOUND_TOKEN);}
YY_BREAK
case 49:
YY_RULE_SETUP
#line 110 "H5LTanalyze.l"
-{return token(H5T_ARRAY_TOKEN);}
+{return token(H5T_ENUM_TOKEN);}
YY_BREAK
case 50:
YY_RULE_SETUP
#line 111 "H5LTanalyze.l"
-{return token(H5T_VLEN_TOKEN);}
+{return token(H5T_ARRAY_TOKEN);}
YY_BREAK
case 51:
YY_RULE_SETUP
-#line 113 "H5LTanalyze.l"
-{return token(H5T_OPAQUE_TOKEN);}
+#line 112 "H5LTanalyze.l"
+{return token(H5T_VLEN_TOKEN);}
YY_BREAK
case 52:
YY_RULE_SETUP
#line 114 "H5LTanalyze.l"
-{return token(OPQ_SIZE_TOKEN);}
+{return token(H5T_OPAQUE_TOKEN);}
YY_BREAK
case 53:
YY_RULE_SETUP
+#line 115 "H5LTanalyze.l"
+{return token(OPQ_SIZE_TOKEN);}
+ YY_BREAK
+case 54:
+YY_RULE_SETUP
#line 116 "H5LTanalyze.l"
+{return token(OPQ_TAG_TOKEN);}
+ YY_BREAK
+case 55:
+YY_RULE_SETUP
+#line 118 "H5LTanalyze.l"
{
- if(is_str_size || (is_enum && is_enum_memb) ||
- is_opq_size || (asindex>-1 && arr_stack[asindex].is_dim)) {
+ if( is_str_size || (is_enum && is_enum_memb) ||
+ is_opq_size || (asindex>-1 && arr_stack[asindex].is_dim) ||
+ (csindex>-1 && cmpd_stack[csindex].is_field) ) {
yylval.ival = atoi(yytext);
return NUMBER;
} else
REJECT;
}
YY_BREAK
-case 54:
+case 56:
YY_RULE_SETUP
-#line 125 "H5LTanalyze.l"
+#line 128 "H5LTanalyze.l"
{
/*if it's first quote, and is a compound field name or an enum symbol*/
- if((is_enum || (csindex>-1 && cmpd_stack[csindex].is_field)) && first_quote) {
+ if((is_opq_tag || is_enum || (csindex>-1 && cmpd_stack[csindex].is_field))
+ && first_quote) {
first_quote = 0;
BEGIN TAG_STRING;
} else /*if it's second quote*/
@@ -1323,56 +1348,61 @@ YY_RULE_SETUP
return token('"');
}
YY_BREAK
-case 55:
+case 57:
YY_RULE_SETUP
-#line 134 "H5LTanalyze.l"
+#line 138 "H5LTanalyze.l"
{
yylval.sval = strdup(yytext);
BEGIN INITIAL;
return STRING;
}
YY_BREAK
-case 56:
+case 58:
YY_RULE_SETUP
-#line 140 "H5LTanalyze.l"
+#line 144 "H5LTanalyze.l"
{return token('{');}
YY_BREAK
-case 57:
+case 59:
YY_RULE_SETUP
-#line 141 "H5LTanalyze.l"
+#line 145 "H5LTanalyze.l"
{return token('}');}
YY_BREAK
-case 58:
+case 60:
YY_RULE_SETUP
-#line 142 "H5LTanalyze.l"
+#line 146 "H5LTanalyze.l"
{return token('[');}
YY_BREAK
-case 59:
+case 61:
YY_RULE_SETUP
-#line 143 "H5LTanalyze.l"
+#line 147 "H5LTanalyze.l"
{return token(']');}
YY_BREAK
-case 60:
+case 62:
YY_RULE_SETUP
-#line 144 "H5LTanalyze.l"
+#line 148 "H5LTanalyze.l"
+{return token(':');}
+ YY_BREAK
+case 63:
+YY_RULE_SETUP
+#line 149 "H5LTanalyze.l"
{return token(';');}
YY_BREAK
-case 61:
+case 64:
YY_RULE_SETUP
-#line 145 "H5LTanalyze.l"
+#line 150 "H5LTanalyze.l"
;
YY_BREAK
-case 62:
+case 65:
YY_RULE_SETUP
-#line 146 "H5LTanalyze.l"
+#line 151 "H5LTanalyze.l"
{ return 0; }
YY_BREAK
-case 63:
+case 66:
YY_RULE_SETUP
-#line 148 "H5LTanalyze.l"
+#line 153 "H5LTanalyze.l"
ECHO;
YY_BREAK
-#line 1355 "H5LTanalyze.c"
+#line 1385 "H5LTanalyze.c"
case YY_STATE_EOF(INITIAL):
case YY_STATE_EOF(TAG_STRING):
yyterminate();
@@ -1662,7 +1692,7 @@ static yy_state_type yy_get_previous_state()
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
{
yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 529 )
+ if ( yy_current_state >= 545 )
yy_c = yy_meta[(unsigned int) yy_c];
}
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
@@ -1692,11 +1722,11 @@ yy_state_type yy_current_state;
while ( yy_chk[yy_base[yy_current_state] + yy_c] != yy_current_state )
{
yy_current_state = (int) yy_def[yy_current_state];
- if ( yy_current_state >= 529 )
+ if ( yy_current_state >= 545 )
yy_c = yy_meta[(unsigned int) yy_c];
}
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
- yy_is_jam = (yy_current_state == 528);
+ yy_is_jam = (yy_current_state == 544);
if ( ! yy_is_jam )
*yy_state_ptr++ = yy_current_state;
@@ -2248,7 +2278,7 @@ int main()
return 0;
}
#endif
-#line 148 "H5LTanalyze.l"
+#line 153 "H5LTanalyze.l"
int my_yyinput(char *buf, int max_size)
{
diff --git a/hl/src/H5LTanalyze.l b/hl/src/H5LTanalyze.l
index f7ea61e..02a4b04 100644
--- a/hl/src/H5LTanalyze.l
+++ b/hl/src/H5LTanalyze.l
@@ -37,10 +37,10 @@ extern hbool_t is_enum_memb;
/*variables for string type*/
extern hbool_t is_str_size;
-extern hbool_t is_str_pad;
/*variables for opaque type*/
extern hbool_t is_opq_size;
+extern hbool_t is_opq_tag;
hbool_t first_quote = 1;
@@ -101,6 +101,7 @@ H5T_STR_NULLTERM {return token(H5T_STR_NULLTERM_TOKEN);}
H5T_STR_NULLPAD {return token(H5T_STR_NULLPAD_TOKEN);}
H5T_STR_SPACEPAD {return token(H5T_STR_SPACEPAD_TOKEN);}
H5T_CSET_ASCII {return token(H5T_CSET_ASCII_TOKEN);}
+H5T_CSET_UTF8 {return token(H5T_CSET_UTF8_TOKEN);}
H5T_C_S1 {return token(H5T_C_S1_TOKEN);}
H5T_FORTRAN_S1 {return token(H5T_FORTRAN_S1_TOKEN);}
H5T_VARIABLE {return token(H5T_VARIABLE_TOKEN);}
@@ -112,10 +113,12 @@ H5T_VLEN {return token(H5T_VLEN_TOKEN);}
H5T_OPAQUE {return token(H5T_OPAQUE_TOKEN);}
OPQ_SIZE {return token(OPQ_SIZE_TOKEN);}
+OPQ_TAG {return token(OPQ_TAG_TOKEN);}
[0-9]+ {
- if(is_str_size || (is_enum && is_enum_memb) ||
- is_opq_size || (asindex>-1 && arr_stack[asindex].is_dim)) {
+ if( is_str_size || (is_enum && is_enum_memb) ||
+ is_opq_size || (asindex>-1 && arr_stack[asindex].is_dim) ||
+ (csindex>-1 && cmpd_stack[csindex].is_field) ) {
yylval.ival = atoi(yytext);
return NUMBER;
} else
@@ -124,7 +127,8 @@ OPQ_SIZE {return token(OPQ_SIZE_TOKEN);}
"\"" {
/*if it's first quote, and is a compound field name or an enum symbol*/
- if((is_enum || (csindex>-1 && cmpd_stack[csindex].is_field)) && first_quote) {
+ if((is_opq_tag || is_enum || (csindex>-1 && cmpd_stack[csindex].is_field))
+ && first_quote) {
first_quote = 0;
BEGIN TAG_STRING;
} else /*if it's second quote*/
@@ -141,6 +145,7 @@ OPQ_SIZE {return token(OPQ_SIZE_TOKEN);}
"}" {return token('}');}
"[" {return token('[');}
"]" {return token(']');}
+":" {return token(':');}
";" {return token(';');}
[ \t\n]* ;
"\n" { return 0; }
diff --git a/hl/src/H5LTparse.c b/hl/src/H5LTparse.c
index 61dbdf1..5abc136 100644
--- a/hl/src/H5LTparse.c
+++ b/hl/src/H5LTparse.c
@@ -66,20 +66,25 @@ int asindex = -1; /*pointer to the top of array stack*/
hbool_t is_str_size = 0; /*flag to lexer for string size*/
hbool_t is_str_pad = 0; /*flag to lexer for string padding*/
-
-hid_t enum_id; /*type ID*/
+H5T_pad_t str_pad; /*variable for string padding*/
+H5T_cset_t str_cset; /*variable for string character set*/
+hbool_t is_variable = 0; /*variable for variable-length string*/
+size_t str_size; /*variable for string size*/
+
+hid_t enum_id; /*type ID*/
hbool_t is_enum = 0; /*flag to lexer for enum type*/
hbool_t is_enum_memb = 0; /*flag to lexer for enum member*/
-char* enum_memb_symbol; /*enum member symbol string*/
+char* enum_memb_symbol; /*enum member symbol string*/
-hbool_t is_opq_size = 0; /*flag to lexer for opaque type size*/
+hbool_t is_opq_size = 0; /*flag to lexer for opaque type size*/
+hbool_t is_opq_tag = 0; /*flag to lexer for opaque type tag*/
-#line 45 "H5LTparse.y"
+#line 50 "H5LTparse.y"
typedef union {
int ival; /*for integer token*/
char *sval; /*for name string*/
} YYSTYPE;
-#line 65 "H5LTparse.c"
+#line 70 "H5LTparse.c"
#define YYERRCODE 256
#define H5T_STD_I8BE_TOKEN 257
#define H5T_STD_I8LE_TOKEN 258
@@ -125,26 +130,29 @@ typedef union {
#define H5T_STR_NULLPAD_TOKEN 298
#define H5T_STR_SPACEPAD_TOKEN 299
#define H5T_CSET_ASCII_TOKEN 300
-#define H5T_C_S1_TOKEN 301
-#define H5T_FORTRAN_S1_TOKEN 302
-#define H5T_OPAQUE_TOKEN 303
-#define OPQ_SIZE_TOKEN 304
-#define H5T_COMPOUND_TOKEN 305
-#define H5T_ENUM_TOKEN 306
-#define H5T_ARRAY_TOKEN 307
-#define H5T_VLEN_TOKEN 308
-#define STRING 309
-#define NUMBER 310
+#define H5T_CSET_UTF8_TOKEN 301
+#define H5T_C_S1_TOKEN 302
+#define H5T_FORTRAN_S1_TOKEN 303
+#define H5T_OPAQUE_TOKEN 304
+#define OPQ_SIZE_TOKEN 305
+#define OPQ_TAG_TOKEN 306
+#define H5T_COMPOUND_TOKEN 307
+#define H5T_ENUM_TOKEN 308
+#define H5T_ARRAY_TOKEN 309
+#define H5T_VLEN_TOKEN 310
+#define STRING 311
+#define NUMBER 312
const short yylhs[] = { -1,
0, 0, 1, 1, 1, 1, 2, 2, 2, 2,
2, 6, 6, 6, 6, 6, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
6, 6, 6, 6, 6, 6, 6, 6, 7, 7,
7, 7, 7, 7, 7, 11, 3, 12, 12, 14,
- 13, 15, 16, 4, 17, 17, 20, 21, 18, 19,
- 5, 23, 24, 10, 22, 26, 28, 29, 31, 33,
- 8, 27, 27, 30, 30, 30, 32, 25, 25, 35,
- 9, 34, 34, 39, 36, 37, 38,
+ 13, 15, 16, 16, 17, 18, 4, 19, 19, 22,
+ 23, 20, 21, 5, 25, 26, 27, 29, 10, 24,
+ 28, 31, 32, 34, 36, 38, 8, 30, 30, 33,
+ 33, 33, 35, 35, 37, 37, 40, 9, 39, 39,
+ 44, 41, 42, 43,
};
const short yylen[] = { 2,
0, 1, 1, 1, 1, 1, 1, 1, 1, 1,
@@ -152,48 +160,55 @@ const short yylen[] = { 2,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 0, 5, 0, 2, 0,
- 6, 1, 0, 6, 0, 2, 0, 0, 5, 1,
- 4, 0, 0, 8, 1, 0, 0, 0, 0, 0,
- 20, 1, 1, 1, 1, 1, 1, 1, 1, 0,
- 7, 0, 2, 0, 6, 1, 1,
+ 7, 1, 0, 2, 1, 0, 6, 0, 2, 0,
+ 0, 5, 1, 4, 0, 0, 0, 0, 15, 1,
+ 1, 0, 0, 0, 0, 0, 20, 1, 1, 1,
+ 1, 1, 1, 1, 1, 1, 0, 7, 0, 2,
+ 0, 6, 1, 1,
};
const short yydefred[] = { 0,
12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
32, 33, 34, 35, 36, 37, 38, 39, 40, 41,
- 42, 43, 44, 45, 0, 0, 46, 0, 53, 0,
+ 42, 43, 44, 45, 0, 0, 46, 0, 56, 0,
0, 2, 3, 4, 5, 6, 7, 8, 9, 10,
- 11, 0, 0, 0, 0, 0, 0, 0, 62, 48,
- 0, 55, 0, 78, 79, 0, 0, 0, 80, 0,
- 61, 66, 65, 0, 47, 50, 49, 82, 57, 0,
- 56, 0, 63, 0, 0, 0, 54, 67, 0, 0,
- 81, 0, 83, 60, 58, 0, 64, 52, 0, 86,
- 0, 0, 72, 73, 0, 0, 84, 59, 68, 51,
- 0, 0, 87, 0, 0, 85, 74, 75, 76, 0,
- 69, 0, 0, 77, 0, 70, 0, 71,
+ 11, 0, 0, 0, 0, 0, 0, 72, 65, 48,
+ 0, 58, 0, 0, 0, 0, 87, 0, 64, 78,
+ 79, 0, 70, 0, 47, 50, 49, 89, 60, 0,
+ 59, 73, 66, 0, 0, 0, 57, 0, 0, 0,
+ 88, 0, 90, 63, 61, 0, 67, 52, 0, 93,
+ 0, 0, 80, 81, 82, 0, 0, 0, 91, 62,
+ 74, 0, 0, 0, 0, 0, 71, 0, 55, 54,
+ 51, 94, 0, 0, 0, 92, 83, 84, 0, 68,
+ 75, 0, 0, 69, 0, 85, 86, 0, 76, 0,
+ 77,
};
const short yydgoto[] = { 41,
42, 43, 44, 45, 46, 47, 48, 49, 50, 51,
- 54, 68, 77, 84, 99, 56, 70, 81, 95, 86,
- 102, 74, 67, 89, 66, 82, 105, 96, 112, 120,
- 122, 125, 127, 85, 78, 93, 101, 114, 111,
+ 54, 66, 77, 84, 99, 114, 120, 56, 68, 81,
+ 95, 86, 102, 74, 65, 89, 107, 118, 132, 72,
+ 64, 88, 106, 116, 129, 133, 138, 140, 85, 78,
+ 93, 101, 123, 115,
};
const short yysindex[] = { -255,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, -81, -80, 0, -79, 0, -78,
+ 0, 0, 0, 0, -82, -79, 0, -78, 0, -76,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, -249, -257, -74, -203, -41, -255, -261, 0, 0,
- 25, 0, -40, 0, 0, 28, -222, -39, 0, -91,
- 0, 0, 0, 30, 0, 0, 0, 0, 0, -35,
- 0, -201, 0, 59, -33, -213, 0, 0, -27, -210,
- 0, -209, 0, 0, 0, -215, 0, 0, 67, 0,
- 68, 10, 0, 0, 45, 46, 0, 0, 0, 0,
- -204, -186, 0, 49, -260, 0, 0, 0, 0, 50,
- 0, -184, -189, 0, 53, 0, -12, 0,
+ 0, -208, -220, -36, -201, -34, -255, 0, 0, 0,
+ 27, 0, -35, -213, -221, -37, 0, -91, 0, 0,
+ 0, 34, 0, 35, 0, 0, 0, 0, 0, -30,
+ 0, 0, 0, 62, -33, -215, 0, -195, -206, -210,
+ 0, -209, 0, 0, 0, -259, 0, 0, 69, 0,
+ 70, 12, 0, 0, 0, 47, 73, 50, 0, 0,
+ 0, -202, -200, 51, -199, -183, 0, 80, 0, 0,
+ 0, 0, 56, -258, 57, 0, 0, 0, 58, 0,
+ 0, -7, -176, 0, -252, 0, 0, 61, 0, -4,
+ 0,
};
-const short yyrindex[] = { 114,
+const short yyrindex[] = { 122,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
@@ -203,32 +218,34 @@ const short yyrindex[] = { 114,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 64, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0,
+ 0,
};
const short yygindex[] = { 0,
- 26, 0, 0, 0, 0, 60, 0, 0, 0, 0,
+ -20, 0, 0, 0, 0, 71, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0,
};
-#define YYTABLESIZE 269
+#define YYTABLESIZE 273
const short yytable[] = { 79,
92, 1, 2, 3, 4, 5, 6, 7, 8, 9,
10, 11, 12, 13, 14, 15, 16, 17, 18, 19,
20, 21, 22, 23, 24, 25, 26, 27, 28, 29,
- 30, 31, 32, 33, 34, 35, 117, 118, 119, 64,
- 65, 52, 53, 55, 57, 58, 59, 36, 60, 37,
- 38, 39, 40, 1, 2, 3, 4, 5, 6, 7,
- 8, 9, 10, 11, 12, 13, 14, 15, 16, 17,
- 18, 19, 20, 21, 22, 23, 24, 25, 26, 27,
- 103, 62, 63, 69, 71, 75, 72, 73, 83, 87,
- 88, 91, 90, 76, 104, 80, 94, 97, 98, 100,
- 106, 107, 108, 109, 110, 113, 115, 116, 121, 123,
- 124, 126, 128, 1, 61, 0, 0, 0, 0, 0,
- 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
+ 30, 31, 32, 33, 34, 35, 63, 103, 104, 105,
+ 52, 127, 128, 53, 55, 76, 57, 80, 36, 136,
+ 137, 37, 38, 39, 40, 1, 2, 3, 4, 5,
+ 6, 7, 8, 9, 10, 11, 12, 13, 14, 15,
+ 16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
+ 26, 27, 70, 58, 59, 67, 60, 75, 62, 69,
+ 73, 91, 82, 83, 87, 90, 94, 96, 71, 97,
+ 98, 100, 108, 109, 110, 111, 112, 113, 117, 121,
+ 124, 119, 122, 125, 126, 130, 131, 134, 135, 139,
+ 141, 1, 53, 0, 0, 61, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
@@ -237,27 +254,28 @@ const short yytable[] = { 79,
16, 17, 18, 19, 20, 21, 22, 23, 24, 25,
26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 36, 0, 37, 38, 39, 40, 1, 2, 3,
- 4, 5, 6, 7, 8, 9, 10, 11, 12, 13,
- 14, 15, 16, 17, 18, 19, 20, 21, 22, 23,
- 24, 25, 26, 27, 28, 29, 30, 31, 32, 33,
- 34, 35, 0, 0, 0, 0, 0, 0, 0, 0,
- 0, 0, 0, 36, 0, 37, 38, 39, 40,
+ 0, 0, 36, 0, 0, 37, 38, 39, 40, 1,
+ 2, 3, 4, 5, 6, 7, 8, 9, 10, 11,
+ 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
+ 22, 23, 24, 25, 26, 27, 28, 29, 30, 31,
+ 32, 33, 34, 35, 0, 0, 0, 0, 0, 0,
+ 0, 0, 0, 0, 0, 0, 36, 0, 0, 37,
+ 38, 39, 40,
};
const short yycheck[] = { 91,
34, 257, 258, 259, 260, 261, 262, 263, 264, 265,
266, 267, 268, 269, 270, 271, 272, 273, 274, 275,
276, 277, 278, 279, 280, 281, 282, 283, 284, 285,
- 286, 287, 288, 289, 290, 291, 297, 298, 299, 301,
- 302, 123, 123, 123, 123, 295, 304, 303, 123, 305,
- 306, 307, 308, 257, 258, 259, 260, 261, 262, 263,
- 264, 265, 266, 267, 268, 269, 270, 271, 272, 273,
- 274, 275, 276, 277, 278, 279, 280, 281, 282, 283,
- 296, 123, 57, 59, 125, 125, 59, 310, 59, 125,
- 292, 125, 34, 68, 310, 70, 310, 125, 309, 309,
- 34, 34, 93, 59, 59, 310, 293, 59, 59, 294,
- 300, 59, 125, 0, 55, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
+ 286, 287, 288, 289, 290, 291, 57, 297, 298, 299,
+ 123, 300, 301, 123, 123, 66, 123, 68, 304, 302,
+ 303, 307, 308, 309, 310, 257, 258, 259, 260, 261,
+ 262, 263, 264, 265, 266, 267, 268, 269, 270, 271,
+ 272, 273, 274, 275, 276, 277, 278, 279, 280, 281,
+ 282, 283, 296, 292, 305, 59, 123, 125, 123, 125,
+ 312, 125, 59, 59, 125, 34, 312, 293, 312, 306,
+ 311, 311, 34, 34, 93, 59, 34, 58, 311, 59,
+ 294, 312, 312, 34, 59, 59, 59, 125, 295, 59,
+ 125, 0, 59, -1, -1, 55, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
@@ -266,27 +284,28 @@ const short yycheck[] = { 91,
272, 273, 274, 275, 276, 277, 278, 279, 280, 281,
282, 283, 284, 285, 286, 287, 288, 289, 290, 291,
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, 303, -1, 305, 306, 307, 308, 257, 258, 259,
- 260, 261, 262, 263, 264, 265, 266, 267, 268, 269,
- 270, 271, 272, 273, 274, 275, 276, 277, 278, 279,
- 280, 281, 282, 283, 284, 285, 286, 287, 288, 289,
- 290, 291, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, 303, -1, 305, 306, 307, 308,
+ -1, -1, 304, -1, -1, 307, 308, 309, 310, 257,
+ 258, 259, 260, 261, 262, 263, 264, 265, 266, 267,
+ 268, 269, 270, 271, 272, 273, 274, 275, 276, 277,
+ 278, 279, 280, 281, 282, 283, 284, 285, 286, 287,
+ 288, 289, 290, 291, -1, -1, -1, -1, -1, -1,
+ -1, -1, -1, -1, -1, -1, 304, -1, -1, 307,
+ 308, 309, 310,
};
#define YYFINAL 41
#ifndef YYDEBUG
#define YYDEBUG 0
#endif
-#define YYMAXTOKEN 310
+#define YYMAXTOKEN 312
#if YYDEBUG
const char * const yyname[] = {
"end-of-file",0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-"'\"'",0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"';'",0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"'['",0,"']'",0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"'{'",0,"'}'",0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+"'\"'",0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"':'","';'",0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"'['",0,"']'",0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,"'{'",0,"'}'",0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
-0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
+0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
"H5T_STD_I8BE_TOKEN","H5T_STD_I8LE_TOKEN","H5T_STD_I16BE_TOKEN",
"H5T_STD_I16LE_TOKEN","H5T_STD_I32BE_TOKEN","H5T_STD_I32LE_TOKEN",
"H5T_STD_I64BE_TOKEN","H5T_STD_I64LE_TOKEN","H5T_STD_U8BE_TOKEN",
@@ -301,9 +320,9 @@ const char * const yyname[] = {
"H5T_NATIVE_LDOUBLE_TOKEN","H5T_STRING_TOKEN","STRSIZE_TOKEN","STRPAD_TOKEN",
"CSET_TOKEN","CTYPE_TOKEN","H5T_VARIABLE_TOKEN","H5T_STR_NULLTERM_TOKEN",
"H5T_STR_NULLPAD_TOKEN","H5T_STR_SPACEPAD_TOKEN","H5T_CSET_ASCII_TOKEN",
-"H5T_C_S1_TOKEN","H5T_FORTRAN_S1_TOKEN","H5T_OPAQUE_TOKEN","OPQ_SIZE_TOKEN",
-"H5T_COMPOUND_TOKEN","H5T_ENUM_TOKEN","H5T_ARRAY_TOKEN","H5T_VLEN_TOKEN",
-"STRING","NUMBER",
+"H5T_CSET_UTF8_TOKEN","H5T_C_S1_TOKEN","H5T_FORTRAN_S1_TOKEN",
+"H5T_OPAQUE_TOKEN","OPQ_SIZE_TOKEN","OPQ_TAG_TOKEN","H5T_COMPOUND_TOKEN",
+"H5T_ENUM_TOKEN","H5T_ARRAY_TOKEN","H5T_VLEN_TOKEN","STRING","NUMBER",
};
const char * const yyrule[] = {
"$accept : start",
@@ -357,8 +376,11 @@ const char * const yyrule[] = {
"memb_list :",
"memb_list : memb_list memb_def",
"$$2 :",
-"memb_def : ddl_type $$2 '\"' field_name '\"' ';'",
+"memb_def : ddl_type $$2 '\"' field_name '\"' field_offset ';'",
"field_name : STRING",
+"field_offset :",
+"field_offset : ':' offset",
+"offset : NUMBER",
"$$3 :",
"array_type : H5T_ARRAY_TOKEN $$3 '{' dim_list ddl_type '}'",
"dim_list :",
@@ -370,28 +392,32 @@ const char * const yyrule[] = {
"vlen_type : H5T_VLEN_TOKEN '{' ddl_type '}'",
"$$6 :",
"$$7 :",
-"opaque_type : H5T_OPAQUE_TOKEN '{' OPQ_SIZE_TOKEN $$6 opaque_size ';' $$7 '}'",
-"opaque_size : NUMBER",
"$$8 :",
"$$9 :",
+"opaque_type : H5T_OPAQUE_TOKEN '{' OPQ_SIZE_TOKEN $$6 opaque_size ';' $$7 OPQ_TAG_TOKEN $$8 '\"' opaque_tag '\"' ';' $$9 '}'",
+"opaque_size : NUMBER",
+"opaque_tag : STRING",
"$$10 :",
"$$11 :",
"$$12 :",
-"string_type : H5T_STRING_TOKEN '{' CTYPE_TOKEN ctype ';' $$8 STRSIZE_TOKEN $$9 strsize ';' $$10 STRPAD_TOKEN strpad ';' $$11 CSET_TOKEN cset ';' $$12 '}'",
+"$$13 :",
+"$$14 :",
+"string_type : H5T_STRING_TOKEN '{' STRSIZE_TOKEN $$10 strsize ';' $$11 STRPAD_TOKEN strpad ';' $$12 CSET_TOKEN cset ';' $$13 CTYPE_TOKEN ctype ';' $$14 '}'",
"strsize : H5T_VARIABLE_TOKEN",
"strsize : NUMBER",
"strpad : H5T_STR_NULLTERM_TOKEN",
"strpad : H5T_STR_NULLPAD_TOKEN",
"strpad : H5T_STR_SPACEPAD_TOKEN",
"cset : H5T_CSET_ASCII_TOKEN",
+"cset : H5T_CSET_UTF8_TOKEN",
"ctype : H5T_C_S1_TOKEN",
"ctype : H5T_FORTRAN_S1_TOKEN",
-"$$13 :",
-"enum_type : H5T_ENUM_TOKEN '{' integer_type ';' $$13 enum_list '}'",
+"$$15 :",
+"enum_type : H5T_ENUM_TOKEN '{' integer_type ';' $$15 enum_list '}'",
"enum_list :",
"enum_list : enum_list enum_def",
-"$$14 :",
-"enum_def : '\"' enum_symbol '\"' $$14 enum_val ';'",
+"$$16 :",
+"enum_def : '\"' enum_symbol '\"' $$16 enum_val ';'",
"enum_symbol : STRING",
"enum_val : NUMBER",
};
@@ -618,155 +644,155 @@ yyreduce:
switch (yyn)
{
case 1:
-#line 77 "H5LTparse.y"
+#line 82 "H5LTparse.y"
{ memset(arr_stack, 0, STACK_SIZE*sizeof(struct arr_info)); /*initialize here?*/ }
break;
case 2:
-#line 78 "H5LTparse.y"
+#line 83 "H5LTparse.y"
{ return yyval.ival;}
break;
case 12:
-#line 92 "H5LTparse.y"
+#line 97 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_I8BE); }
break;
case 13:
-#line 93 "H5LTparse.y"
+#line 98 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_I8LE); }
break;
case 14:
-#line 94 "H5LTparse.y"
+#line 99 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_I16BE); }
break;
case 15:
-#line 95 "H5LTparse.y"
+#line 100 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_I16LE); }
break;
case 16:
-#line 96 "H5LTparse.y"
+#line 101 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_I32BE); }
break;
case 17:
-#line 97 "H5LTparse.y"
+#line 102 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_I32LE); }
break;
case 18:
-#line 98 "H5LTparse.y"
+#line 103 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_I64BE); }
break;
case 19:
-#line 99 "H5LTparse.y"
+#line 104 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_I64LE); }
break;
case 20:
-#line 100 "H5LTparse.y"
+#line 105 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_U8BE); }
break;
case 21:
-#line 101 "H5LTparse.y"
+#line 106 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_U8LE); }
break;
case 22:
-#line 102 "H5LTparse.y"
+#line 107 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_U16BE); }
break;
case 23:
-#line 103 "H5LTparse.y"
+#line 108 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_U16LE); }
break;
case 24:
-#line 104 "H5LTparse.y"
+#line 109 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_U32BE); }
break;
case 25:
-#line 105 "H5LTparse.y"
+#line 110 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_U32LE); }
break;
case 26:
-#line 106 "H5LTparse.y"
+#line 111 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_U64BE); }
break;
case 27:
-#line 107 "H5LTparse.y"
+#line 112 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_STD_U64LE); }
break;
case 28:
-#line 108 "H5LTparse.y"
+#line 113 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_CHAR); }
break;
case 29:
-#line 109 "H5LTparse.y"
+#line 114 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_SCHAR); }
break;
case 30:
-#line 110 "H5LTparse.y"
+#line 115 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_UCHAR); }
break;
case 31:
-#line 111 "H5LTparse.y"
+#line 116 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_SHORT); }
break;
case 32:
-#line 112 "H5LTparse.y"
+#line 117 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_USHORT); }
break;
case 33:
-#line 113 "H5LTparse.y"
+#line 118 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_INT); }
break;
case 34:
-#line 114 "H5LTparse.y"
+#line 119 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_UINT); }
break;
case 35:
-#line 115 "H5LTparse.y"
+#line 120 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_LONG); }
break;
case 36:
-#line 116 "H5LTparse.y"
+#line 121 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_ULONG); }
break;
case 37:
-#line 117 "H5LTparse.y"
+#line 122 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_LLONG); }
break;
case 38:
-#line 118 "H5LTparse.y"
+#line 123 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_ULLONG); }
break;
case 39:
-#line 121 "H5LTparse.y"
+#line 126 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_IEEE_F32BE); }
break;
case 40:
-#line 122 "H5LTparse.y"
+#line 127 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_IEEE_F32LE); }
break;
case 41:
-#line 123 "H5LTparse.y"
+#line 128 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_IEEE_F64BE); }
break;
case 42:
-#line 124 "H5LTparse.y"
+#line 129 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_IEEE_F64LE); }
break;
case 43:
-#line 125 "H5LTparse.y"
+#line 130 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_FLOAT); }
break;
case 44:
-#line 126 "H5LTparse.y"
+#line 131 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_DOUBLE); }
break;
case 45:
-#line 127 "H5LTparse.y"
+#line 132 "H5LTparse.y"
{ yyval.ival = H5Tcopy(H5T_NATIVE_LDOUBLE); }
break;
case 46:
-#line 131 "H5LTparse.y"
+#line 136 "H5LTparse.y"
{ csindex++; cmpd_stack[csindex].id = H5Tcreate(H5T_COMPOUND, 1); /*temporarily set size to 1*/ }
break;
case 47:
-#line 133 "H5LTparse.y"
+#line 138 "H5LTparse.y"
{ yyval.ival = cmpd_stack[csindex].id;
cmpd_stack[csindex].id = 0;
cmpd_stack[csindex].first_memb = 1;
@@ -774,41 +800,63 @@ case 47:
}
break;
case 50:
-#line 142 "H5LTparse.y"
+#line 147 "H5LTparse.y"
{ cmpd_stack[csindex].is_field = 1; /*notify lexer a compound member is parsed*/ }
break;
case 51:
-#line 144 "H5LTparse.y"
-{ int origin_size, new_size;
+#line 149 "H5LTparse.y"
+{
+ int origin_size, new_size;
hid_t dtype_id = cmpd_stack[csindex].id;
- /*Adjust size and insert member. Leave no space between.*/
+ /*Adjust size and insert member, consider both member size and offset.*/
if(cmpd_stack[csindex].first_memb) { /*reclaim the size 1 temporarily set*/
- new_size = H5Tget_size(yyvsp[-5].ival);
+ new_size = H5Tget_size(yyvsp[-6].ival) + yyvsp[-1].ival;
H5Tset_size(dtype_id, new_size);
/*member name is saved in yylval.sval by lexer*/
- H5Tinsert(dtype_id, yylval.sval, 0, yyvsp[-5].ival);
+ H5Tinsert(dtype_id, yyvsp[-3].sval, yyvsp[-1].ival, yyvsp[-6].ival);
cmpd_stack[csindex].first_memb = 0;
} else {
origin_size = H5Tget_size(dtype_id);
- new_size = origin_size + H5Tget_size(yyvsp[-5].ival);
- H5Tset_size(dtype_id, new_size);
- H5Tinsert(dtype_id, yylval.sval, origin_size, yyvsp[-5].ival);
+
+ if(yyvsp[-1].ival == 0) {
+ new_size = origin_size + H5Tget_size(yyvsp[-6].ival);
+ H5Tset_size(dtype_id, new_size);
+ H5Tinsert(dtype_id, yyvsp[-3].sval, origin_size, yyvsp[-6].ival);
+ } else {
+ new_size = yyvsp[-1].ival + H5Tget_size(yyvsp[-6].ival);
+ H5Tset_size(dtype_id, new_size);
+ H5Tinsert(dtype_id, yyvsp[-3].sval, yyvsp[-1].ival, yyvsp[-6].ival);
+ }
}
cmpd_stack[csindex].is_field = 0;
- H5Tclose(yyvsp[-5].ival);
+ H5Tclose(yyvsp[-6].ival);
new_size = H5Tget_size(dtype_id);
}
break;
+case 52:
+#line 182 "H5LTparse.y"
+{
+ yyval.sval = yylval.sval;
+ }
+break;
case 53:
-#line 171 "H5LTparse.y"
-{ asindex++; /*pushd onto the stack*/ }
+#line 187 "H5LTparse.y"
+{ yyval.ival = 0; }
break;
case 54:
-#line 173 "H5LTparse.y"
+#line 189 "H5LTparse.y"
+{ yyval.ival = yylval.ival; }
+break;
+case 56:
+#line 193 "H5LTparse.y"
+{ asindex++; /*pushd onto the stack*/ }
+break;
+case 57:
+#line 195 "H5LTparse.y"
{
yyval.ival = H5Tarray_create(yyvsp[-1].ival, arr_stack[asindex].ndims, arr_stack[asindex].dims, NULL);
arr_stack[asindex].ndims = 0;
@@ -816,128 +864,160 @@ case 54:
H5Tclose(yyvsp[-1].ival);
}
break;
-case 57:
-#line 183 "H5LTparse.y"
+case 60:
+#line 205 "H5LTparse.y"
{ arr_stack[asindex].is_dim = 1; /*notice lexer of dimension size*/ }
break;
-case 58:
-#line 184 "H5LTparse.y"
+case 61:
+#line 206 "H5LTparse.y"
{ int ndims = arr_stack[asindex].ndims;
arr_stack[asindex].dims[ndims] = (hsize_t)yylval.ival;
arr_stack[asindex].ndims++;
arr_stack[asindex].is_dim = 0;
}
break;
-case 61:
-#line 195 "H5LTparse.y"
+case 64:
+#line 217 "H5LTparse.y"
{ yyval.ival = H5Tvlen_create(yyvsp[-1].ival); H5Tclose(yyvsp[-1].ival); }
break;
-case 62:
-#line 200 "H5LTparse.y"
+case 65:
+#line 222 "H5LTparse.y"
{ is_opq_size = 1; }
break;
-case 63:
-#line 201 "H5LTparse.y"
+case 66:
+#line 223 "H5LTparse.y"
{
size_t size = (size_t)yylval.ival;
yyval.ival = H5Tcreate(H5T_OPAQUE, size);
is_opq_size = 0;
}
break;
-case 64:
-#line 206 "H5LTparse.y"
-{ yyval.ival = yyvsp[-1].ival; }
+case 67:
+#line 228 "H5LTparse.y"
+{ is_opq_tag = 1; }
break;
-case 66:
-#line 214 "H5LTparse.y"
-{
- if(yyvsp[-1].ival == H5T_C_S1_TOKEN)
- yyval.ival = H5Tcopy(H5T_C_S1);
- else if(yyvsp[-1].ival == H5T_FORTRAN_S1_TOKEN)
- yyval.ival = H5Tcopy(H5T_FORTRAN_S1);
+case 68:
+#line 229 "H5LTparse.y"
+{
+ H5Tset_tag(yyvsp[-6].ival, yylval.sval);
+ is_opq_tag = 0;
}
break;
-case 67:
-#line 220 "H5LTparse.y"
+case 69:
+#line 233 "H5LTparse.y"
+{ yyval.ival = yyvsp[-8].ival; }
+break;
+case 72:
+#line 241 "H5LTparse.y"
{ is_str_size = 1; }
break;
-case 68:
-#line 221 "H5LTparse.y"
+case 73:
+#line 242 "H5LTparse.y"
{
if(yyvsp[-1].ival == H5T_VARIABLE_TOKEN)
- H5Tset_size(yyvsp[-4].ival, H5T_VARIABLE);
+ is_variable = 1;
else
- H5Tset_size(yyvsp[-4].ival, yylval.ival);
+ str_size = yylval.ival;
is_str_size = 0;
}
break;
-case 69:
-#line 229 "H5LTparse.y"
+case 74:
+#line 250 "H5LTparse.y"
{
if(yyvsp[-1].ival == H5T_STR_NULLTERM_TOKEN)
- H5Tset_strpad(yyvsp[-8].ival, H5T_STR_NULLTERM);
+ str_pad = H5T_STR_NULLTERM;
else if(yyvsp[-1].ival == H5T_STR_NULLPAD_TOKEN)
- H5Tset_strpad(yyvsp[-8].ival, H5T_STR_NULLPAD);
+ str_pad = H5T_STR_NULLPAD;
else if(yyvsp[-1].ival == H5T_STR_SPACEPAD_TOKEN)
- H5Tset_strpad(yyvsp[-8].ival, H5T_STR_SPACEPAD);
+ str_pad = H5T_STR_SPACEPAD;
}
break;
-case 70:
-#line 238 "H5LTparse.y"
+case 75:
+#line 259 "H5LTparse.y"
{
if(yyvsp[-1].ival == H5T_CSET_ASCII_TOKEN)
- H5Tset_cset(yyvsp[-12].ival, H5T_CSET_ASCII);
+ str_cset = H5T_CSET_ASCII;
+ else if(yyvsp[-1].ival == H5T_CSET_UTF8_TOKEN)
+ str_cset = H5T_CSET_UTF8;
}
break;
-case 71:
-#line 242 "H5LTparse.y"
-{ yyval.ival = yyvsp[-14].ival; }
+case 76:
+#line 266 "H5LTparse.y"
+{
+ if(yyvsp[-1].ival == H5T_C_S1_TOKEN)
+ yyval.ival = H5Tcopy(H5T_C_S1);
+ else if(yyvsp[-1].ival == H5T_FORTRAN_S1_TOKEN)
+ yyval.ival = H5Tcopy(H5T_FORTRAN_S1);
+ }
break;
-case 72:
-#line 245 "H5LTparse.y"
+case 77:
+#line 273 "H5LTparse.y"
+{
+ hid_t str_id = yyvsp[-1].ival;
+
+ /*set string size*/
+ if(is_variable) {
+ H5Tset_size(str_id, H5T_VARIABLE);
+ is_variable = 0;
+ } else
+ H5Tset_size(str_id, str_size);
+
+ /*set string padding and character set*/
+ H5Tset_strpad(str_id, str_pad);
+ H5Tset_cset(str_id, str_cset);
+
+ yyval.ival = str_id;
+ }
+break;
+case 78:
+#line 290 "H5LTparse.y"
{yyval.ival = H5T_VARIABLE_TOKEN;}
break;
-case 74:
-#line 248 "H5LTparse.y"
+case 80:
+#line 293 "H5LTparse.y"
{yyval.ival = H5T_STR_NULLTERM_TOKEN;}
break;
-case 75:
-#line 249 "H5LTparse.y"
+case 81:
+#line 294 "H5LTparse.y"
{yyval.ival = H5T_STR_NULLPAD_TOKEN;}
break;
-case 76:
-#line 250 "H5LTparse.y"
+case 82:
+#line 295 "H5LTparse.y"
{yyval.ival = H5T_STR_SPACEPAD_TOKEN;}
break;
-case 77:
-#line 252 "H5LTparse.y"
+case 83:
+#line 297 "H5LTparse.y"
{yyval.ival = H5T_CSET_ASCII_TOKEN;}
break;
-case 78:
-#line 254 "H5LTparse.y"
+case 84:
+#line 298 "H5LTparse.y"
+{yyval.ival = H5T_CSET_UTF8_TOKEN;}
+break;
+case 85:
+#line 300 "H5LTparse.y"
{yyval.ival = H5T_C_S1_TOKEN;}
break;
-case 79:
-#line 255 "H5LTparse.y"
+case 86:
+#line 301 "H5LTparse.y"
{yyval.ival = H5T_FORTRAN_S1_TOKEN;}
break;
-case 80:
-#line 259 "H5LTparse.y"
+case 87:
+#line 305 "H5LTparse.y"
{ is_enum = 1; enum_id = H5Tenum_create(yyvsp[-1].ival); H5Tclose(yyvsp[-1].ival); }
break;
-case 81:
-#line 261 "H5LTparse.y"
+case 88:
+#line 307 "H5LTparse.y"
{ is_enum = 0; /*reset*/ yyval.ival = enum_id; }
break;
-case 84:
-#line 266 "H5LTparse.y"
+case 91:
+#line 312 "H5LTparse.y"
{
is_enum_memb = 1; /*indicate member of enum*/
enum_memb_symbol = strdup(yylval.sval);
}
break;
-case 85:
-#line 271 "H5LTparse.y"
+case 92:
+#line 317 "H5LTparse.y"
{
int memb_val;
if(is_enum && is_enum_memb) { /*if it's an enum member*/
@@ -947,7 +1027,7 @@ case 85:
}
}
break;
-#line 933 "H5LTparse.c"
+#line 1013 "H5LTparse.c"
}
yyssp -= yym;
yystate = *yyssp;
diff --git a/hl/src/H5LTparse.h b/hl/src/H5LTparse.h
index 4be1a8e..5210d7e 100644
--- a/hl/src/H5LTparse.h
+++ b/hl/src/H5LTparse.h
@@ -15,7 +15,6 @@
/* This file was generated by Yacc with the command "yacc -o H5LTparse.c -d H5LTparse.y"
* Do NOT modify it by hand.
*/
-
#ifndef YYERRCODE
#define YYERRCODE 256
#endif
@@ -64,16 +63,18 @@
#define H5T_STR_NULLPAD_TOKEN 298
#define H5T_STR_SPACEPAD_TOKEN 299
#define H5T_CSET_ASCII_TOKEN 300
-#define H5T_C_S1_TOKEN 301
-#define H5T_FORTRAN_S1_TOKEN 302
-#define H5T_OPAQUE_TOKEN 303
-#define OPQ_SIZE_TOKEN 304
-#define H5T_COMPOUND_TOKEN 305
-#define H5T_ENUM_TOKEN 306
-#define H5T_ARRAY_TOKEN 307
-#define H5T_VLEN_TOKEN 308
-#define STRING 309
-#define NUMBER 310
+#define H5T_CSET_UTF8_TOKEN 301
+#define H5T_C_S1_TOKEN 302
+#define H5T_FORTRAN_S1_TOKEN 303
+#define H5T_OPAQUE_TOKEN 304
+#define OPQ_SIZE_TOKEN 305
+#define OPQ_TAG_TOKEN 306
+#define H5T_COMPOUND_TOKEN 307
+#define H5T_ENUM_TOKEN 308
+#define H5T_ARRAY_TOKEN 309
+#define H5T_VLEN_TOKEN 310
+#define STRING 311
+#define NUMBER 312
typedef union {
int ival; /*for integer token*/
char *sval; /*for name string*/
diff --git a/hl/src/H5LTparse.y b/hl/src/H5LTparse.y
index c5f8520..0961a76 100644
--- a/hl/src/H5LTparse.y
+++ b/hl/src/H5LTparse.y
@@ -33,13 +33,18 @@ int asindex = -1; /*pointer to the top of array stack*/
hbool_t is_str_size = 0; /*flag to lexer for string size*/
hbool_t is_str_pad = 0; /*flag to lexer for string padding*/
-
-hid_t enum_id; /*type ID*/
+H5T_pad_t str_pad; /*variable for string padding*/
+H5T_cset_t str_cset; /*variable for string character set*/
+hbool_t is_variable = 0; /*variable for variable-length string*/
+size_t str_size; /*variable for string size*/
+
+hid_t enum_id; /*type ID*/
hbool_t is_enum = 0; /*flag to lexer for enum type*/
hbool_t is_enum_memb = 0; /*flag to lexer for enum member*/
-char* enum_memb_symbol; /*enum member symbol string*/
+char* enum_memb_symbol; /*enum member symbol string*/
-hbool_t is_opq_size = 0; /*flag to lexer for opaque type size*/
+hbool_t is_opq_size = 0; /*flag to lexer for opaque type size*/
+hbool_t is_opq_tag = 0; /*flag to lexer for opaque type tag*/
%}
%union {
@@ -60,9 +65,9 @@ hbool_t is_opq_size = 0; /*flag to lexer for opaque type size*/
%token <ival> H5T_STRING_TOKEN STRSIZE_TOKEN STRPAD_TOKEN CSET_TOKEN CTYPE_TOKEN H5T_VARIABLE_TOKEN
%token <ival> H5T_STR_NULLTERM_TOKEN H5T_STR_NULLPAD_TOKEN H5T_STR_SPACEPAD_TOKEN
-%token <ival> H5T_CSET_ASCII_TOKEN H5T_C_S1_TOKEN H5T_FORTRAN_S1_TOKEN
+%token <ival> H5T_CSET_ASCII_TOKEN H5T_CSET_UTF8_TOKEN H5T_C_S1_TOKEN H5T_FORTRAN_S1_TOKEN
-%token <ival> H5T_OPAQUE_TOKEN OPQ_SIZE_TOKEN
+%token <ival> H5T_OPAQUE_TOKEN OPQ_SIZE_TOKEN OPQ_TAG_TOKEN
%token <ival> H5T_COMPOUND_TOKEN
%token <ival> H5T_ENUM_TOKEN
@@ -71,7 +76,7 @@ hbool_t is_opq_size = 0; /*flag to lexer for opaque type size*/
%token <sval> STRING
%token <ival> NUMBER
-%token <ival> '{' '}' '[' ']' '"' ';'
+%token <ival> '{' '}' '[' ']' '"' ':' ';'
%%
start : { memset(arr_stack, 0, STACK_SIZE*sizeof(struct arr_info)); /*initialize here?*/ }
@@ -140,23 +145,31 @@ memb_list :
| memb_list memb_def
;
memb_def : ddl_type { cmpd_stack[csindex].is_field = 1; /*notify lexer a compound member is parsed*/ }
- '"' field_name '"' ';'
- { int origin_size, new_size;
+ '"' field_name '"' field_offset ';'
+ {
+ int origin_size, new_size;
hid_t dtype_id = cmpd_stack[csindex].id;
- /*Adjust size and insert member. Leave no space between.*/
+ /*Adjust size and insert member, consider both member size and offset.*/
if(cmpd_stack[csindex].first_memb) { /*reclaim the size 1 temporarily set*/
- new_size = H5Tget_size($<ival>1);
+ new_size = H5Tget_size($<ival>1) + $<ival>6;
H5Tset_size(dtype_id, new_size);
/*member name is saved in yylval.sval by lexer*/
- H5Tinsert(dtype_id, yylval.sval, 0, $<ival>1);
+ H5Tinsert(dtype_id, $<sval>4, $<ival>6, $<ival>1);
cmpd_stack[csindex].first_memb = 0;
} else {
origin_size = H5Tget_size(dtype_id);
- new_size = origin_size + H5Tget_size($<ival>1);
- H5Tset_size(dtype_id, new_size);
- H5Tinsert(dtype_id, yylval.sval, origin_size, $<ival>1);
+
+ if($<ival>6 == 0) {
+ new_size = origin_size + H5Tget_size($<ival>1);
+ H5Tset_size(dtype_id, new_size);
+ H5Tinsert(dtype_id, $<sval>4, origin_size, $<ival>1);
+ } else {
+ new_size = $<ival>6 + H5Tget_size($<ival>1);
+ H5Tset_size(dtype_id, new_size);
+ H5Tinsert(dtype_id, $<sval>4, $<ival>6, $<ival>1);
+ }
}
cmpd_stack[csindex].is_field = 0;
@@ -166,8 +179,17 @@ memb_def : ddl_type { cmpd_stack[csindex].is_field = 1; /*notify le
}
;
field_name : STRING
+ {
+ $<sval>$ = yylval.sval;
+ }
+ ;
+field_offset : /*empty*/
+ { $<ival>$ = 0; }
+ | ':' offset
+ { $<ival>$ = yylval.ival; }
+ ;
+offset : NUMBER
;
-
array_type : H5T_ARRAY_TOKEN { asindex++; /*pushd onto the stack*/ }
'{' dim_list ddl_type '}'
{
@@ -202,45 +224,68 @@ opaque_type : H5T_OPAQUE_TOKEN
size_t size = (size_t)yylval.ival;
$<ival>$ = H5Tcreate(H5T_OPAQUE, size);
is_opq_size = 0;
- }
+ }
+ OPQ_TAG_TOKEN { is_opq_tag = 1; } '"' opaque_tag '"' ';'
+ {
+ H5Tset_tag($<ival>7, yylval.sval);
+ is_opq_tag = 0;
+ }
'}' { $<ival>$ = $<ival>7; }
;
opaque_size : NUMBER
;
-
+opaque_tag : STRING
+ ;
string_type : H5T_STRING_TOKEN
'{'
- CTYPE_TOKEN ctype ';'
- {
- if($<ival>4 == H5T_C_S1_TOKEN)
- $<ival>$ = H5Tcopy(H5T_C_S1);
- else if($<ival>4 == H5T_FORTRAN_S1_TOKEN)
- $<ival>$ = H5Tcopy(H5T_FORTRAN_S1);
- }
STRSIZE_TOKEN { is_str_size = 1; } strsize ';'
{
- if($<ival>9 == H5T_VARIABLE_TOKEN)
- H5Tset_size($<ival>6, H5T_VARIABLE);
+ if($<ival>5 == H5T_VARIABLE_TOKEN)
+ is_variable = 1;
else
- H5Tset_size($<ival>6, yylval.ival);
+ str_size = yylval.ival;
is_str_size = 0;
}
STRPAD_TOKEN strpad ';'
{
- if($<ival>13 == H5T_STR_NULLTERM_TOKEN)
- H5Tset_strpad($<ival>6, H5T_STR_NULLTERM);
- else if($<ival>13 == H5T_STR_NULLPAD_TOKEN)
- H5Tset_strpad($<ival>6, H5T_STR_NULLPAD);
- else if($<ival>13 == H5T_STR_SPACEPAD_TOKEN)
- H5Tset_strpad($<ival>6, H5T_STR_SPACEPAD);
+ if($<ival>9 == H5T_STR_NULLTERM_TOKEN)
+ str_pad = H5T_STR_NULLTERM;
+ else if($<ival>9 == H5T_STR_NULLPAD_TOKEN)
+ str_pad = H5T_STR_NULLPAD;
+ else if($<ival>9 == H5T_STR_SPACEPAD_TOKEN)
+ str_pad = H5T_STR_SPACEPAD;
}
CSET_TOKEN cset ';'
{
- if($<ival>17 == H5T_CSET_ASCII_TOKEN)
- H5Tset_cset($<ival>6, H5T_CSET_ASCII);
+ if($<ival>13 == H5T_CSET_ASCII_TOKEN)
+ str_cset = H5T_CSET_ASCII;
+ else if($<ival>13 == H5T_CSET_UTF8_TOKEN)
+ str_cset = H5T_CSET_UTF8;
}
- '}' { $<ival>$ = $<ival>6; }
+ CTYPE_TOKEN ctype ';'
+ {
+ if($<ival>17 == H5T_C_S1_TOKEN)
+ $<ival>$ = H5Tcopy(H5T_C_S1);
+ else if($<ival>17 == H5T_FORTRAN_S1_TOKEN)
+ $<ival>$ = H5Tcopy(H5T_FORTRAN_S1);
+ }
+ '}'
+ {
+ hid_t str_id = $<ival>19;
+ /*set string size*/
+ if(is_variable) {
+ H5Tset_size(str_id, H5T_VARIABLE);
+ is_variable = 0;
+ } else
+ H5Tset_size(str_id, str_size);
+
+ /*set string padding and character set*/
+ H5Tset_strpad(str_id, str_pad);
+ H5Tset_cset(str_id, str_cset);
+
+ $<ival>$ = str_id;
+ }
;
strsize : H5T_VARIABLE_TOKEN {$<ival>$ = H5T_VARIABLE_TOKEN;}
| NUMBER
@@ -250,6 +295,7 @@ strpad : H5T_STR_NULLTERM_TOKEN {$<ival>$ = H5T_STR_NULLTERM_TOKE
| H5T_STR_SPACEPAD_TOKEN {$<ival>$ = H5T_STR_SPACEPAD_TOKEN;}
;
cset : H5T_CSET_ASCII_TOKEN {$<ival>$ = H5T_CSET_ASCII_TOKEN;}
+ | H5T_CSET_UTF8_TOKEN {$<ival>$ = H5T_CSET_UTF8_TOKEN;}
;
ctype : H5T_C_S1_TOKEN {$<ival>$ = H5T_C_S1_TOKEN;}
| H5T_FORTRAN_S1_TOKEN {$<ival>$ = H5T_FORTRAN_S1_TOKEN;}
diff --git a/hl/test/test_lite.c b/hl/test/test_lite.c
index 533147a..b7e1af5 100644
--- a/hl/test/test_lite.c
+++ b/hl/test/test_lite.c
@@ -1054,22 +1054,22 @@ static int test_integers(void)
TESTING3("\n text for integer types");
- if((dtype = H5LTtext_to_dtype("H5T_NATIVE_INT\n"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_NATIVE_INT\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_NATIVE_INT))
goto out;
if(H5Tclose(dtype)<0)
goto out;
- if((dtype = H5LTtext_to_dtype("H5T_STD_I8BE\n"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_STD_I8BE\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_STD_I8BE))
goto out;
- if(H5LTdtype_to_text(dtype, NULL, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
- if(H5LTdtype_to_text(dtype, dt_str, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
goto out;
if(strcmp(dt_str, "H5T_STD_I8BE"))
goto out;
@@ -1078,7 +1078,7 @@ static int test_integers(void)
if(H5Tclose(dtype)<0)
goto out;
- if((dtype = H5LTtext_to_dtype("H5T_STD_U16LE\n"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_STD_U16LE\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_STD_U16LE))
goto out;
@@ -1105,22 +1105,22 @@ static int test_fps(void)
TESTING3(" text for floating-point types");
- if((dtype = H5LTtext_to_dtype("H5T_NATIVE_LDOUBLE\n"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_NATIVE_LDOUBLE\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_NATIVE_LDOUBLE))
goto out;
if(H5Tclose(dtype)<0)
goto out;
- if((dtype = H5LTtext_to_dtype("H5T_IEEE_F32BE\n"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_IEEE_F32BE\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_IEEE_F32BE))
goto out;
- if(H5LTdtype_to_text(dtype, NULL, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
- if(H5LTdtype_to_text(dtype, dt_str, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
goto out;
if(strcmp(dt_str, "H5T_IEEE_F32BE"))
goto out;
@@ -1129,7 +1129,7 @@ static int test_fps(void)
if(H5Tclose(dtype)<0)
goto out;
- if((dtype = H5LTtext_to_dtype("H5T_IEEE_F64LE\n"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_IEEE_F64LE\n", H5LT_DDL))<0)
goto out;
if(!H5Tequal(dtype, H5T_IEEE_F64LE))
goto out;
@@ -1160,7 +1160,7 @@ static int test_strings(void)
TESTING3(" text for string types");
- if((dtype = H5LTtext_to_dtype("H5T_STRING { CTYPE H5T_C_S1; STRSIZE 13; STRPAD H5T_STR_NULLTERM; CSET H5T_CSET_ASCII; }"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_STRING { STRSIZE 13; STRPAD H5T_STR_NULLTERM; CSET H5T_CSET_ASCII; CTYPE H5T_C_S1; }", H5LT_DDL))<0)
goto out;
if((type_class = H5Tget_class(dtype))<0)
@@ -1180,12 +1180,12 @@ static int test_strings(void)
if(str_cset != H5T_CSET_ASCII)
goto out;
- if(H5LTdtype_to_text(dtype, NULL, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
- if(H5LTdtype_to_text(dtype, dt_str, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
goto out;
- if(strcmp(dt_str, "H5T_STRING {\n CTYPE H5T_C_S1;\n STRSIZE 13;\n STRPAD H5T_STR_NULLTERM;\n CSET H5T_CSET_ASCII;\n }")) {
+ if(strcmp(dt_str, "H5T_STRING {\n STRSIZE 13;\n STRPAD H5T_STR_NULLTERM;\n CSET H5T_CSET_ASCII;\n CTYPE H5T_C_S1;\n }")) {
printf("dt=\n%s\n", dt_str);
goto out;
}
@@ -1194,7 +1194,7 @@ static int test_strings(void)
if(H5Tclose(dtype)<0)
goto out;
- if((dtype = H5LTtext_to_dtype("H5T_STRING { CTYPE H5T_C_S1; STRSIZE H5T_VARIABLE; STRPAD H5T_STR_NULLPAD; CSET H5T_CSET_ASCII; }"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_STRING { STRSIZE H5T_VARIABLE; STRPAD H5T_STR_NULLPAD; CSET H5T_CSET_ASCII; CTYPE H5T_C_S1; }", H5LT_DDL))<0)
goto out;
if(!H5Tis_variable_str(dtype))
@@ -1208,12 +1208,12 @@ static int test_strings(void)
if(str_cset != H5T_CSET_ASCII)
goto out;
- if(H5LTdtype_to_text(dtype, NULL, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
- if(H5LTdtype_to_text(dtype, dt_str, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
goto out;
- if(strcmp(dt_str, "H5T_STRING {\n CTYPE H5T_C_S1;\n STRSIZE H5T_VARIABLE;\n STRPAD H5T_STR_NULLPAD;\n CSET H5T_CSET_ASCII;\n }")) {
+ if(strcmp(dt_str, "H5T_STRING {\n STRSIZE H5T_VARIABLE;\n STRPAD H5T_STR_NULLPAD;\n CSET H5T_CSET_ASCII;\n CTYPE H5T_C_S1;\n }")) {
printf("dt=\n%s\n", dt_str);
goto out;
}
@@ -1244,7 +1244,7 @@ static int test_opaques(void)
TESTING3(" text for opaque types");
- if((dtype = H5LTtext_to_dtype("H5T_OPAQUE { OPQ_SIZE 19; }"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_OPAQUE { OPQ_SIZE 19; OPQ_TAG \"This is a tag for opaque type\"; }", H5LT_DDL))<0)
goto out;
if((type_class = H5Tget_class(dtype))<0)
@@ -1257,12 +1257,12 @@ static int test_opaques(void)
if(opq_size != 19)
goto out;
- if(H5LTdtype_to_text(dtype, NULL, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
- if(H5LTdtype_to_text(dtype, dt_str, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
goto out;
- if(strcmp(dt_str, "H5T_OPAQUE {\n OPQ_SIZE 19;\n }")) {
+ if(strcmp(dt_str, "H5T_OPAQUE {\n OPQ_SIZE 19;\n OPQ_TAG \"This is a tag for opaque type\";\n }")) {
printf("dt=\n%s\n", dt_str);
goto out;
}
@@ -1297,7 +1297,7 @@ static int test_enums(void)
TESTING3(" text for enum types");
- if((dtype = H5LTtext_to_dtype("H5T_ENUM { H5T_STD_I32LE; \"RED\" 5; \"GREEN\" 6; \"BLUE\" 7; \"WHITE\" 8; }"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_ENUM { H5T_STD_I32LE; \"RED\" 5; \"GREEN\" 6; \"BLUE\" 7; \"WHITE\" 8; }", H5LT_DDL))<0)
goto out;
if((type_class = H5Tget_class(dtype))<0)
@@ -1315,10 +1315,10 @@ static int test_enums(void)
if(value2 != 8)
goto out;
- if(H5LTdtype_to_text(dtype, NULL, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
- if(H5LTdtype_to_text(dtype, dt_str, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
goto out;
/*if(strcmp(dt_str, "H5T_ENUM {\n H5T_STD_I32LE;\n \"RED\" 5;\n \"GREEN\" 6;\n \"BLUE\" 7;\n \"WHITE\" 8;\n }")) {
printf("dt=\n%s\n", dt_str);
@@ -1350,7 +1350,7 @@ static int test_variables(void)
TESTING3(" text for variable types");
- if((dtype = H5LTtext_to_dtype("H5T_VLEN { H5T_NATIVE_CHAR }\n"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_VLEN { H5T_NATIVE_CHAR }\n", H5LT_DDL))<0)
goto out;
if((type_class = H5Tget_class(dtype))<0)
@@ -1364,16 +1364,16 @@ static int test_variables(void)
if(H5Tclose(dtype)<0)
goto out;
- if((dtype = H5LTtext_to_dtype("H5T_VLEN { H5T_VLEN { H5T_STD_I32BE } }"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_VLEN { H5T_VLEN { H5T_STD_I32BE } }", H5LT_DDL))<0)
goto out;
if(H5Tis_variable_str(dtype))
goto out;
- if(H5LTdtype_to_text(dtype, NULL, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
- if(H5LTdtype_to_text(dtype, dt_str, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
goto out;
if(strcmp(dt_str, "H5T_VLEN {\n H5T_VLEN {\n H5T_STD_I32BE\n }\n }")) {
printf("dt=\n%s\n", dt_str);
@@ -1407,7 +1407,7 @@ static int test_arrays(void)
TESTING3(" text for array types");
- if((dtype = H5LTtext_to_dtype("H5T_ARRAY { [5][7][13] H5T_ARRAY { [17][19] H5T_COMPOUND { H5T_STD_I8BE \"arr_compound_1\"; H5T_STD_I32BE \"arr_compound_2\"; } } }"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_ARRAY { [5][7][13] H5T_ARRAY { [17][19] H5T_COMPOUND { H5T_STD_I8BE \"arr_compound_1\"; H5T_STD_I32BE \"arr_compound_2\"; } } }", H5LT_DDL))<0)
goto out;
if((type_class = H5Tget_class(dtype))<0)
@@ -1425,10 +1425,10 @@ static int test_arrays(void)
if(dims[0] != 5 || dims[1] != 7 || dims[2] != 13)
goto out;
- if(H5LTdtype_to_text(dtype, NULL, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
- if(H5LTdtype_to_text(dtype, dt_str, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
goto out;
/*if(strcmp(dt_str, "H5T_ARRAY { [5][7][13] H5T_ARRAY { [17][19] H5T_COMPOUND { H5T_STD_I8BE \"arr_compound_1\"; H5T_STD_I32BE \"arr_compound_2\"; } } }")) {
printf("dt=\n%s\n", dt_str);
@@ -1463,7 +1463,7 @@ static int test_compounds(void)
TESTING3(" text for compound types");
- if((dtype = H5LTtext_to_dtype("H5T_COMPOUND { H5T_STD_I16BE \"one_field\"; H5T_STD_U8LE \"two_field\"; }"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_COMPOUND { H5T_STD_I16BE \"one_field\" : 2; H5T_STD_U8LE \"two_field\" : 6; }", H5LT_DDL))<0)
goto out;
if((type_class = H5Tget_class(dtype))<0)
@@ -1476,12 +1476,12 @@ static int test_compounds(void)
if(nmembs != 2)
goto out;
- if(H5LTdtype_to_text(dtype, NULL, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, NULL, H5LT_DDL, &str_len)<0)
goto out;
dt_str = (char*)calloc(str_len, sizeof(char));
- if(H5LTdtype_to_text(dtype, dt_str, &str_len)<0)
+ if(H5LTdtype_to_text(dtype, dt_str, H5LT_DDL, &str_len)<0)
goto out;
- if(strcmp(dt_str, "H5T_COMPOUND {\n H5T_STD_I16BE \"one_field\";\n H5T_STD_U8LE \"two_field\";\n }")) {
+ if(strcmp(dt_str, "H5T_COMPOUND {\n H5T_STD_I16BE \"one_field\" : 2;\n H5T_STD_U8LE \"two_field\" : 6;\n }")) {
printf("dt=\n%s\n", dt_str);
goto out;
}
@@ -1490,7 +1490,7 @@ static int test_compounds(void)
if(H5Tclose(dtype)<0)
goto out;
- if((dtype = H5LTtext_to_dtype("H5T_COMPOUND { H5T_STD_I32BE \"i32_field\"; H5T_STD_I16BE \"i16_field\"; H5T_COMPOUND { H5T_STD_I16BE \"sec_field\"; H5T_COMPOUND { H5T_STD_I32BE \"thd_field\"; } \"grandchild\"; } \"child_compound\"; H5T_STD_I8BE \"i8_field\"; }"))<0)
+ if((dtype = H5LTtext_to_dtype("H5T_COMPOUND { H5T_STD_I32BE \"i32_field\"; H5T_STD_I16BE \"i16_field\"; H5T_COMPOUND { H5T_STD_I16BE \"sec_field\"; H5T_COMPOUND { H5T_STD_I32BE \"thd_field\"; } \"grandchild\"; } \"child_compound\"; H5T_STD_I8BE \"i8_field\"; }", H5LT_DDL))<0)
goto out;
if((memb_name = H5Tget_member_name(dtype, 1)) == NULL)