From 1204798fffa03a70f7c52ed635e6cd1b3ba78bd9 Mon Sep 17 00:00:00 2001 From: Juerg Billeter Date: Fri, 23 Nov 2007 20:25:57 +0000 Subject: add support for anonymous structs and unions (gcc extension) 2007-11-23 Juerg Billeter * gobject-introspection/cparser.y: add support for anonymous structs and unions (gcc extension) svn path=/trunk/; revision=711 --- gobject-introspection/cparser.y | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'gobject-introspection') diff --git a/gobject-introspection/cparser.y b/gobject-introspection/cparser.y index d432fd3ee..415607e9b 100644 --- a/gobject-introspection/cparser.y +++ b/gobject-introspection/cparser.y @@ -739,7 +739,11 @@ struct_declarator_list ; struct_declarator - : declarator + : /* empty, support for anonymous structs and unions */ + { + $$ = csymbol_new (CSYMBOL_TYPE_INVALID); + } + | declarator | ':' constant_expression { $$ = csymbol_new (CSYMBOL_TYPE_INVALID); -- cgit v1.2.1