From: compudj Date: Fri, 16 Dec 2005 22:49:09 +0000 (+0000) Subject: update parser to fit LTTV X-Git-Tag: v0.12.20~2077 X-Git-Url: https://git.lttng.org./?a=commitdiff_plain;h=bf6349fa9ea59eee25fb045f4d1acf9b2544fc73;p=lttv.git update parser to fit LTTV git-svn-id: http://ltt.polymtl.ca/svn@1412 04897980-b3bd-0310-b5e0-8ef037075253 --- diff --git a/genevent-new/parser.c b/genevent-new/parser.c index 42c38c31..bfa64564 100644 --- a/genevent-new/parser.c +++ b/genevent-new/parser.c @@ -182,7 +182,6 @@ void getTypeAttributes(parse_file_t *in, type_descriptor_t *t, t->fmt = NULL; t->size = 0; - t->alignment = 0; while(1) { token = getToken(in); @@ -203,9 +202,6 @@ void getTypeAttributes(parse_file_t *in, type_descriptor_t *t, } else if(!strcmp("size",token)) { getEqual(in); t->size = getSize(in); - } else if(!strcmp("align",token)) { - getEqual(in); - t->alignment = getNumber(in); } } } @@ -733,10 +729,10 @@ type_descriptor_t *parseType(parse_file_t *in, type_descriptor_t *inType, t->already_printed = 0; getTypeAttributes(in, t, unnamed_types, named_types); //if(t->size == 0) in->error(in, "Sequence has empty size"); - //Mathieu : we fix enum size to 4 bytes. GCC is always like this. + //Mathieu : we fix enum size to target int size. GCC is always like this. //fox copy optimisation. - if(t->size != 0) in->error(in, "Enum has fixed size of 4."); - t->size = 4; + if(t->size != 0) in->error(in, "Enum has fixed size of target int."); + t->size = 0; getRAnglebracket(in); //