Fix switch/case last case validation for ESSL 3.10

No statement should be required after the last case label of a switch
statement in ESSL 3.10. The validation is still kept for ESSL 3.00 for
dEQP compatibility. If the dEQP tests are changed in the future, we
might consider just issuing a warning regardless of shader version.

BUG=angleproject:2189
TEST=angle_unittests

Change-Id: Ic53e71e0176668a7dbffa315712885846e217f03
Reviewed-on: https://chromium-review.googlesource.com/727802
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
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 e5f9f59..6631e49 100644
--- a/src/compiler/translator/ParseContext.cpp
+++ b/src/compiler/translator/ParseContext.cpp
@@ -4640,8 +4640,9 @@
     }
 
     ASSERT(statementList);
-    if (!ValidateSwitchStatementList(switchType, mDiagnostics, statementList, loc))
+    if (!ValidateSwitchStatementList(switchType, mShaderVersion, mDiagnostics, statementList, loc))
     {
+        ASSERT(mDiagnostics->numErrors() > 0);
         return nullptr;
     }