diff options
author | Patrick Welche <prlw1@cam.ac.uk> | 2013-04-20 12:34:15 +0100 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2013-04-20 18:12:44 -0400 |
commit | 962ab98e926e886a476b76ad641c30718a0a6e84 (patch) | |
tree | a225770afd45b6048b8f332d40111017d269c65f /giscanner | |
parent | 82870258bb3e8a284d893ac46a6afc2dd426d49a (diff) | |
download | gobject-introspection-962ab98e926e886a476b76ad641c30718a0a6e84.tar.gz |
giscanner/scannerlexer.l: Parse and ignore more __asm and __volatile
In the spirit of c9708af2 also parse and ignore
__asm [whitespace] volatile
__asm__ [whitespace] volatile
__volatile
__volatile__
Ignoring __volatile is cosmetic, but the __asm cases avoid an unwanted
VOLATILE token. Extension of
https://bugzilla.gnome.org/show_bug.cgi?id=678794
Diffstat (limited to 'giscanner')
-rw-r--r-- | giscanner/scannerlexer.l | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/giscanner/scannerlexer.l b/giscanner/scannerlexer.l index 65fa3c29..f8fd3703 100644 --- a/giscanner/scannerlexer.l +++ b/giscanner/scannerlexer.l @@ -137,6 +137,8 @@ stringtext ([^\\\"])|(\\.) "," { return ','; } "->" { return ARROW; } +"__asm"[\t\f\v\r ]+"volatile" { if (!parse_ignored_macro()) REJECT; } +"__asm__"[\t\f\v\r ]+"volatile" { if (!parse_ignored_macro()) REJECT; } "__asm" { if (!parse_ignored_macro()) REJECT; } "__asm__" { if (!parse_ignored_macro()) REJECT; } "__attribute__" { if (!parse_ignored_macro()) REJECT; } @@ -148,6 +150,8 @@ stringtext ([^\\\"])|(\\.) "__signed__" { return SIGNED; } "__restrict" { return RESTRICT; } "__typeof" { if (!parse_ignored_macro()) REJECT; } +"__volatile" { if (!parse_ignored_macro()) REJECT; } +"__volatile__" { if (!parse_ignored_macro()) REJECT; } "_Bool" { return BOOL; } "G_GINT64_CONSTANT" { return INTL_CONST; } |