Fix clang warning: ConstantUnion.h:56:17: warning: 7 enumeration values not handled in switch
Issue=124
Part 1 of 5: <http://webkit.org/b/56337> Enable -Werror on ANGLE
Signed-off-by: Nicolas Capens
Signed-off-by: Daniel Koch
Upstream bug: <http://code.google.com/p/angleproject/issues/detail?id=124>
Fixes the following static analyzer warning:
In file included from src/compiler/debug.cpp:14:
In file included from src/compiler/ParseHelper.h:10:
In file included from src/compiler/localintermediate.h:11:
In file included from src/compiler/intermediate.h:21:
src/compiler/ConstantUnion.h:56:17: warning: 7 enumeration values not handled in switch: 'EbtVoid', 'EbtGuardSamplerBegin', 'EbtSampler2D'... [-Wswitch-enum,2]
switch (type) {
^
* src/compiler/ConstantUnion.h:
(ConstantUnion::operator==): Added a default case.
Author: David Kilzer <ddkilzer@apple.com>
git-svn-id: https://angleproject.googlecode.com/svn/trunk@572 736b8ea6-26fd-11df-bfd4-992fa37f6226
diff --git a/src/compiler/ConstantUnion.h b/src/compiler/ConstantUnion.h
index 5b986b8..d28a11b 100644
--- a/src/compiler/ConstantUnion.h
+++ b/src/compiler/ConstantUnion.h
@@ -51,6 +51,8 @@
return constant.fConst == fConst;
case EbtBool:
return constant.bConst == bConst;
+ default:
+ return false;
}
return false;