From 2ffb49b6c3457af45fad96a91fc0279b08c06abb Mon Sep 17 00:00:00 2001 From: Mike Kestner Date: Sun, 9 Jan 2011 11:27:15 -0600 Subject: [PATCH] Pass typedef struct _Foo Foo; through gapi_pp. * parser/gapi_pp.pl: in source files, still pass simple struct typedefs through to support parsing gio 2.27.90. No idea why they are hiding signal vm declarations in gdbusauthobserver. --- parser/gapi_pp.pl | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/parser/gapi_pp.pl b/parser/gapi_pp.pl index 070d73848..c2dd9e67c 100755 --- a/parser/gapi_pp.pl +++ b/parser/gapi_pp.pl @@ -205,7 +205,7 @@ foreach $fname (@srcs, @privhdrs) { } while ($line = ) { - next if ($line !~ /^(struct|\w+_class_init|\w+_base_init|\w+_get_type\b|G_DEFINE_TYPE_WITH_CODE)/); + next if ($line !~ /^(struct|typedef struct.*;|\w+_class_init|\w+_base_init|\w+_get_type\b|G_DEFINE_TYPE_WITH_CODE)/); if ($line =~ /^G_DEFINE_TYPE_WITH_CODE/) { my $macro; @@ -235,6 +235,9 @@ foreach $fname (@srcs, @privhdrs) { print $line; next; } + } elsif ($line =~ /^typedef.*;/) { + print $line; + next; } $comment = 0;