пора домой

This commit is contained in:
Kolan Sh 2011-07-12 19:13:22 +04:00
parent fdf76df377
commit 76a2b5a904
1 changed files with 15 additions and 4 deletions

View File

@ -79,7 +79,6 @@ void tex_parse(const char *source, size_t len, struct tex_struct_s **tex_struct,
zclear(&tag);
where_stack[++tex_level] = IN_TAG;
} else if (isspace(c)) {
where_stack[++tex_level] = IN_SPACE;
@ -155,11 +154,16 @@ void tex_parse(const char *source, size_t len, struct tex_struct_s **tex_struct,
if (param)
printf("IN_TAGPARM: {%s}\n", param);
#endif
if (tex_level && where_stack[tex_level - 1] == IN_TAG_BEGIN
&& !strcmp(param, TEX_PARAM_TABLE))
where_stack[tex_level++] = IN_TABLE;
if (tex_level && where_stack[tex_level - 1] == IN_TAG_END
&& !strcmp(param, TEX_PARAM_TABLE))
where_stack[tex_level--] = IN_UNDEF;
/*if (tex_level && where_stack[tex_level - 1] == IN_TAG_BEGIN
&& !strcmp(param, TEX_PARAM_TABLE))
where_stack[tex_level++] = IN_TABLE;*/
where_stack[tex_level--] = IN_UNDEF;
} else if (c == '\\') { // new tag
zclear(&tag);
@ -217,6 +221,13 @@ void tex_parse(const char *source, size_t len, struct tex_struct_s **tex_struct,
case IN_FORMULA:
break;
case IN_TABLE:
*tex_struct = zalloc_append64(*tex_struct,
break;
default: