cimaron/glsl2js — pull request #18 by DelvarWorld (2014-10-24 02:07:36+00:00)
Title: Fixing parenthesis madness

The first commit is for the specific problem of expressions not getting re-compiled correctly if they are `a + ( 1 + 2 )` for example. I'm a little worried looking at the rest of the grammar file because it looks like there are lots of things left in this state, like `iteration_statement:`, which will require a lot of hand maintenance to convert to AstNodes properly.

The second commit (which I can make into a separate PR if you wish) fixes the always-grouping behavior of parenthesis. I thought of two ways to do this. one being to create an AstGroupedNode, or this way. Because the spec does not make any specific mention of a grouped node type, just:

primary_expression:
...
LEFT_PAREN expression RIGHT_PAREN

I figured it was better to add a flag to the expression node. Thoughts?