Commit 2a517272 by Zhenyao Mo

Fix an issue with separate invariant statement.

Basically we end up with an extra "invariant xxx ;;" on GL backend. This is not handled correctly by Mac drivers and also out shader translator. BUG=angle:776 TEST=webgl conformance on mac/windows Change-Id: If32867efba64ab0d3e6e690155790b90d736439f Reviewed-on: https://chromium-review.googlesource.com/225780Tested-by: 's avatarZhenyao Mo <zmo@chromium.org> Reviewed-by: 's avatarJamie Madill <jmadill@chromium.org>
parent fe14d455
...@@ -658,7 +658,7 @@ bool TOutputGLSLBase::visitAggregate(Visit visit, TIntermAggregate *node) ...@@ -658,7 +658,7 @@ bool TOutputGLSLBase::visitAggregate(Visit visit, TIntermAggregate *node)
ASSERT(sequence && sequence->size() == 1); ASSERT(sequence && sequence->size() == 1);
const TIntermSymbol *symbol = sequence->front()->getAsSymbolNode(); const TIntermSymbol *symbol = sequence->front()->getAsSymbolNode();
ASSERT(symbol); ASSERT(symbol);
out << "invariant " << hashVariableName(symbol->getSymbol()) << ";"; out << "invariant " << hashVariableName(symbol->getSymbol());
} }
visitChildren = false; visitChildren = false;
break; break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment