Enable -Wimplicit-fallthrough for ANGLE.
Also teach MSVC that ANGLE_CRASH() can't return.
Also fix instances of the warning in build configurations where
UNREACHABLE() can return (e.g. release without dcheck_always_on
or debug).
If the UNREACHABLE()s are truly unreachable, this change has
no behavior change.
Bug: chromium:810767
Change-Id: I68f3587cf3e268c3ef634dce7ae3d70399859d0f
Reviewed-on: https://chromium-review.googlesource.com/914842
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Nico Weber <thakis@chromium.org>
Commit-Queue: Nico Weber <thakis@chromium.org>
diff --git a/src/compiler/translator/ParseContext.cpp b/src/compiler/translator/ParseContext.cpp
index 1d069a4..ecab1fc 100644
--- a/src/compiler/translator/ParseContext.cpp
+++ b/src/compiler/translator/ParseContext.cpp
@@ -4993,10 +4993,9 @@
case EOpIndexDirect:
case EOpIndexIndirect:
break;
- case EOpIndexDirectStruct:
- UNREACHABLE();
default:
+ ASSERT(op != EOpIndexDirectStruct);
error(loc, "Invalid operation for variables with an opaque type",
GetOperatorString(op));
return false;