Commit f3c92311 by apatrick@chromium.org

Fix remaining compiler warnings in translator_common.

One MSVC warning and one GCC warning. I also added a variable to build_angle.gyp that will enforce various rules not normally applied to third party software when built as part of chromium. Review URL: https://codereview.appspot.com/5570061 git-svn-id: https://angleproject.googlecode.com/svn/trunk@962 736b8ea6-26fd-11df-bfd4-992fa37f6226
parent e0f059c5
......@@ -3,6 +3,9 @@
# found in the LICENSE file.
{
'variables': {
'chromium_code': 1,
},
'target_defaults': {
'defines': [
'ANGLE_DISABLE_TRACE',
......@@ -13,9 +16,6 @@
{
'target_name': 'translator_common',
'type': 'static_library',
'variables': {
'warn_as_error': 0,
},
'include_dirs': [
'.',
'../include',
......
#define MAJOR_VERSION 1
#define MINOR_VERSION 0
#define BUILD_VERSION 0
#define BUILD_REVISION 961
#define BUILD_REVISION 962
#define STRINGIFY(x) #x
#define MACRO_STRINGIFY(x) STRINGIFY(x)
......
......@@ -482,6 +482,8 @@ void updateExtensionBehavior(const char* extName, const char* behavior)
msg = TString("extension '") + extName + "' is not supported";
context->infoSink.info.message(EPrefixWarning, msg.c_str(), yylineno);
break;
default:
break;
}
return;
} else
......
......@@ -3130,6 +3130,8 @@ void updateExtensionBehavior(const char* extName, const char* behavior)
msg = TString("extension '") + extName + "' is not supported";
context->infoSink.info.message(EPrefixWarning, msg.c_str(), yylineno);
break;
default:
break;
}
return;
} else
......
......@@ -1726,12 +1726,8 @@ yydestruct (yymsg, yytype, yyvaluep, context)
yymsg = "Deleting";
YY_SYMBOL_PRINT (yymsg, yytype, yyvaluep, yylocationp);
switch (yytype)
{
default:
break;
}
// Delete any automatically generated switch with no cases code that appears
// here. It will produce a warning (and therefore an error) in MSVC.
}
/* Prevent warnings from -Wmissing-prototypes. */
......
......@@ -53,6 +53,7 @@
WarningLevel="3"
Detect64BitPortabilityProblems="false"
DebugInformationFormat="4"
WarnAsError="true"
/>
<Tool
Name="VCManagedResourceCompilerTool"
......@@ -116,6 +117,7 @@
WarningLevel="3"
Detect64BitPortabilityProblems="false"
DebugInformationFormat="3"
WarnAsError="true"
/>
<Tool
Name="VCManagedResourceCompilerTool"
......@@ -180,6 +182,7 @@
WarningLevel="3"
Detect64BitPortabilityProblems="false"
DebugInformationFormat="3"
WarnAsError="true"
/>
<Tool
Name="VCManagedResourceCompilerTool"
......@@ -244,6 +247,7 @@
WarningLevel="3"
Detect64BitPortabilityProblems="false"
DebugInformationFormat="3"
WarnAsError="true"
/>
<Tool
Name="VCManagedResourceCompilerTool"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment