diff options
Diffstat (limited to 'share/qbs/modules/cpp/sdcc.js')
-rw-r--r-- | share/qbs/modules/cpp/sdcc.js | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/share/qbs/modules/cpp/sdcc.js b/share/qbs/modules/cpp/sdcc.js index 8b502bd8a..928ded5cf 100644 --- a/share/qbs/modules/cpp/sdcc.js +++ b/share/qbs/modules/cpp/sdcc.js @@ -286,18 +286,18 @@ function compilerFlags(project, product, input, outputs, explicitlyDependsOn) { // C language version flags. if (tag === "c") { - var knownValues = ["c11", "c99", "c89"]; + var knownValues = ["c2x", "c17", "c11", "c99", "c89"]; var cLanguageVersion = Cpp.languageVersion( input.cpp.cLanguageVersion, knownValues, "C"); switch (cLanguageVersion) { + case "c17": + cLanguageVersion = "c11"; + // fall through case "c89": - args.push("--std-c89"); - break; case "c99": - args.push("--std-c99"); - break; case "c11": - args.push("--std-c11"); + case "c2x": + args.push("--std-" + cLanguageVersion); break; } } |