Remove TFunctionSymbolInfo from TIntermAggregate
All the information stored in TFunctionSymbolInfo was duplicated from
the TFunction that the aggregate node pointed to.
BUG=angleproject:2267
TEST=angle_unittests
Change-Id: I1f5574ab0416e5cae00c3dae6fc11d2fe1fa128c
Reviewed-on: https://chromium-review.googlesource.com/827065
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
diff --git a/src/compiler/translator/ParseContext.cpp b/src/compiler/translator/ParseContext.cpp
index 1ead5a5..8ed358d 100644
--- a/src/compiler/translator/ParseContext.cpp
+++ b/src/compiler/translator/ParseContext.cpp
@@ -5483,7 +5483,7 @@
void TParseContext::checkTextureGather(TIntermAggregate *functionCall)
{
ASSERT(functionCall->getOp() == EOpCallBuiltInFunction);
- const TString &name = functionCall->getFunctionSymbolInfo()->getName();
+ const TString &name = *functionCall->getFunction()->name();
bool isTextureGather = (name == "textureGather");
bool isTextureGatherOffset = (name == "textureGatherOffset");
if (isTextureGather || isTextureGatherOffset)
@@ -5549,7 +5549,7 @@
void TParseContext::checkTextureOffsetConst(TIntermAggregate *functionCall)
{
ASSERT(functionCall->getOp() == EOpCallBuiltInFunction);
- const TString &name = functionCall->getFunctionSymbolInfo()->getName();
+ const TString &name = *functionCall->getFunction()->name();
TIntermNode *offset = nullptr;
TIntermSequence *arguments = functionCall->getSequence();
bool useTextureGatherOffsetConstraints = false;
@@ -5625,7 +5625,8 @@
void TParseContext::checkAtomicMemoryBuiltinFunctions(TIntermAggregate *functionCall)
{
- const TString &name = functionCall->getFunctionSymbolInfo()->getName();
+ ASSERT(functionCall->getOp() == EOpCallBuiltInFunction);
+ const TString &name = *functionCall->getFunction()->name();
if (IsAtomicBuiltin(name))
{
TIntermSequence *arguments = functionCall->getSequence();
@@ -5648,7 +5649,7 @@
error(memNode->getLine(),
"The value passed to the mem argument of an atomic memory function does not "
"correspond to a buffer or shared variable.",
- functionCall->getFunctionSymbolInfo()->getName().c_str());
+ functionCall->getFunction()->name()->c_str());
}
}
@@ -5656,7 +5657,7 @@
void TParseContext::checkImageMemoryAccessForBuiltinFunctions(TIntermAggregate *functionCall)
{
ASSERT(functionCall->getOp() == EOpCallBuiltInFunction);
- const TString &name = functionCall->getFunctionSymbolInfo()->getName();
+ const TString &name = *functionCall->getFunction()->name();
if (name.compare(0, 5, "image") == 0)
{