Created
June 27, 2012 12:18
-
-
Save fjolnir/3003700 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Property = obj:Variable | |
{ | |
PushStack([NSMutableArray array]); | |
} | |
- PropSubscr+ | |
{ | |
NSMutableArray *subscripts = PopStack(); | |
$$ = [TQNodeMemberAccess nodeWithReceiver:obj property:[subscript objectAtIndex:0]]; | |
for(int i = 1; i < [subscripts count]; ++i) { | |
$$ = [TQNodeMemberAccess nodeWithReceiver:$$ property:[subscript objectAtIndex:i]]; | |
} | |
} | |
PropSubscr = "#" - prop:Identifier { [StackTop addObject:prop]; } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment