Make sure that the AST root is always a sequence node
This enables inserting helper functions as an AST transformation.
BUG=angleproject:1116
TEST=angle_unittests
Change-Id: I169d4d3a726d0e389cb3444fe9dfb4c6c5d80155
Reviewed-on: https://chromium-review.googlesource.com/290513
Tested-by: Olli Etuaho <oetuaho@nvidia.com>
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Zhenyao Mo <zmo@chromium.org>
diff --git a/src/compiler/translator/Intermediate.h b/src/compiler/translator/Intermediate.h
index e5c69d9..21d0b1d 100644
--- a/src/compiler/translator/Intermediate.h
+++ b/src/compiler/translator/Intermediate.h
@@ -60,7 +60,7 @@
TIntermBranch *addBranch(TOperator, const TSourceLoc &);
TIntermBranch *addBranch(TOperator, TIntermTyped *, const TSourceLoc &);
TIntermTyped *addSwizzle(TVectorFields &, const TSourceLoc &);
- bool postProcess(TIntermNode *);
+ TIntermAggregate *postProcess(TIntermNode *root);
static void outputTree(TIntermNode *, TInfoSinkBase &);