diff options
author | Andy Schwerin <schwerin@mongodb.com> | 2015-03-12 13:26:30 -0400 |
---|---|---|
committer | Andy Schwerin <schwerin@mongodb.com> | 2015-03-12 17:11:20 -0400 |
commit | 7ee3d124070db157181bc1b24f2b84913957c388 (patch) | |
tree | 3a78fec498abf1ea536727bc4179c84f70b82a6c /SConstruct | |
parent | 3bb26d2bb96b65177019fb78297a94d50e4acc67 (diff) | |
download | mongo-7ee3d124070db157181bc1b24f2b84913957c388.tar.gz |
SERVER-17568 Report most-vexing-parse warning as error in MSVC.
Diffstat (limited to 'SConstruct')
-rw-r--r-- | SConstruct | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/SConstruct b/SConstruct index 6efb01156d0..1deefc6b399 100644 --- a/SConstruct +++ b/SConstruct @@ -901,7 +901,13 @@ elif windows: # identifier' : type name first seen using 'objecttype1' now seen using 'objecttype2' # This warning occurs when classes and structs are declared with a mix of struct and class # which can cause linker failures - env.Append( CCFLAGS=["/we4099"] ) + # c4930 + # 'identifier': prototyped function not called (was a variable definition intended?) + # This warning indicates a most-vexing parse error, where a user declared a function that + # was probably intended as a variable definition. A common example is accidentally + # declaring a function called lock that takes a mutex when one meant to create a guard + # object called lock on the stack. + env.Append( CCFLAGS=["/we4099", "/we4930"] ) env.Append( CPPDEFINES=["_CONSOLE","_CRT_SECURE_NO_WARNINGS"] ) |