Merge "Map cpp_std c++17/gnu++17 to 1z."
This commit is contained in:
@@ -365,11 +365,15 @@ func (compiler *baseCompiler) compilerFlags(ctx ModuleContext, flags Flags) Flag
|
|||||||
cStd = compiler.Properties.C_std
|
cStd = compiler.Properties.C_std
|
||||||
}
|
}
|
||||||
|
|
||||||
cppStd := config.CppStdVersion
|
cppStd := compiler.Properties.Cpp_std
|
||||||
if compiler.Properties.Cpp_std == "experimental" {
|
switch compiler.Properties.Cpp_std {
|
||||||
|
case "":
|
||||||
|
cppStd = config.CppStdVersion
|
||||||
|
case "experimental":
|
||||||
cppStd = config.ExperimentalCppStdVersion
|
cppStd = config.ExperimentalCppStdVersion
|
||||||
} else if compiler.Properties.Cpp_std != "" {
|
case "c++17", "gnu++17":
|
||||||
cppStd = compiler.Properties.Cpp_std
|
// Map c++17 and gnu++17 to their 1z equivalents, until 17 is finalized.
|
||||||
|
cppStd = strings.Replace(compiler.Properties.Cpp_std, "17", "1z", 1)
|
||||||
}
|
}
|
||||||
|
|
||||||
if !flags.Clang {
|
if !flags.Clang {
|
||||||
|
Reference in New Issue
Block a user