Skip to content

Commit 03625bf

Browse files
committed
Parse preprocessor directives within structs
Previously, this would result in an error being raised.
1 parent 77f3f98 commit 03625bf

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lib/index.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -756,6 +756,11 @@ function parser() {
756756
, function() { state.scope.enter(); return Advance }
757757
, advance('{')
758758
, function() {
759+
if(token.type === 'preprocessor') {
760+
state.fake(adhoc())
761+
tokens.shift()
762+
return
763+
}
759764
if(token.data === '}') {
760765
state.scope.exit()
761766
tokens.shift()

0 commit comments

Comments
 (0)