[core] Add High as a new warning level

Maps to /W4 on VS and -Wall for gcc/clang removing -Wextra
This commit is contained in:
Patrick Doane 2017-06-28 15:26:56 -07:00 committed by Tom van Dijck
parent 5ecd0a3102
commit e49b404d73
5 changed files with 15 additions and 0 deletions

View File

@ -1250,6 +1250,7 @@
allowed = {
"Off",
"Default",
"High",
"Extra",
}
}

View File

@ -78,6 +78,7 @@
},
warnings = {
Extra = "-Wall -Wextra",
High = "-Wall",
Off = "-w",
},
symbols = {

View File

@ -84,6 +84,7 @@
},
warnings = {
Extra = "/W4",
High = "/W4",
Off = "/W0",
},
stringpooling = {

View File

@ -80,6 +80,12 @@
test.contains({ "-Wall -Wextra" }, gcc.getcflags(cfg))
end
function suite.cflags_onHighWarnings()
warnings "high"
prepare()
test.contains({ "-Wall" }, gcc.getcflags(cfg))
end
function suite.cflags_onFatalWarnings()
flags { "FatalWarnings" }
prepare()

View File

@ -181,6 +181,12 @@
test.contains("/W0", msc.getcflags(cfg))
end
function suite.cflags_OnHighWarnings()
warnings "High"
prepare()
test.contains("/W4", msc.getcflags(cfg))
end
function suite.cflags_OnExtraWarnings()
warnings "Extra"
prepare()