Remove TIntermSymbol::setId

The only place it was being used was when parsing array declarators.
The declarator only needs to be added to the AST when the variable
has successfully been declared, so this usage was not necessary.

BUG=angleproject:1490
TEST=angle_unittests

Change-Id: I05b8851cfdebc9253c9fda8b12733f23da604ca6
Reviewed-on: https://chromium-review.googlesource.com/569160
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
Commit-Queue: Olli Etuaho <oetuaho@nvidia.com>
diff --git a/src/compiler/translator/ParseContext.cpp b/src/compiler/translator/ParseContext.cpp
index af722ce..80889b3 100644
--- a/src/compiler/translator/ParseContext.cpp
+++ b/src/compiler/translator/ParseContext.cpp
@@ -2480,12 +2480,13 @@
         TVariable *variable = nullptr;
         declareVariable(identifierLocation, identifier, arrayType, &variable);
 
-        TIntermSymbol *symbol = new TIntermSymbol(0, identifier, arrayType);
-        symbol->setLine(identifierLocation);
         if (variable)
-            symbol->setId(variable->getUniqueId());
-
-        declarationOut->appendDeclarator(symbol);
+        {
+            TIntermSymbol *symbol =
+                new TIntermSymbol(variable->getUniqueId(), identifier, arrayType);
+            symbol->setLine(identifierLocation);
+            declarationOut->appendDeclarator(symbol);
+        }
     }
 }