Micro-optimize uniform updates.

This CL is adapted from work by matavenrath@nvidia.com. It does the
following small optimizations:

* inlines a bunch of accessors.
* reorders checks to hit the cache more often

Also some small style updates.

Bug: angleproject:1671
Change-Id: I8f21318e6644dcfe1f99c98f7f377742fcad78d3
Reviewed-on: https://chromium-review.googlesource.com/1054367
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
diff --git a/src/libANGLE/validationES.cpp b/src/libANGLE/validationES.cpp
index 56d6e76..cbf4ef2 100644
--- a/src/libANGLE/validationES.cpp
+++ b/src/libANGLE/validationES.cpp
@@ -2096,7 +2096,7 @@
     const auto &uniform = program->getUniformByIndex(uniformLocation.index);
 
     // attempting to write an array to a non-array uniform is an INVALID_OPERATION
-    if (!uniform.isArray() && count > 1)
+    if (count > 1 && !uniform.isArray())
     {
         context->handleError(InvalidOperation());
         return false;