fix compile standard for msvc
All checks were successful
build-dsl-smoke / Build judge (push) Successful in 13s
build-dsl-smoke / debug / clang / linux (push) Successful in 6s
build-dsl-smoke / debug / gcc / linux (push) Successful in 9s
build-dsl-smoke / release / clang / linux (push) Successful in 9s
build-dsl-smoke / release / gcc / linux (push) Successful in 9s
build-dsl-smoke / sanitized / clang / linux (push) Successful in 10s
build-dsl-smoke / sanitized / gcc / linux (push) Successful in 9s
build-dsl-smoke / debug / clang / windows (push) Successful in 18s
build-dsl-smoke / debug-valgrind / gcc / linux (push) Successful in 18s
build-dsl-smoke / debug / msvc / windows (push) Successful in 20s
build-dsl-smoke / release / clang / windows (push) Successful in 16s
build-dsl-smoke / release / msvc / windows (push) Successful in 17s
build-dsl-smoke / SUMMARY (push) Successful in 4s
Release / Build & publish (push) Successful in 49s

This commit is contained in:
2026-04-15 11:02:05 +03:00
parent ea2ca49f0f
commit 52202abb53

View File

@@ -134,6 +134,14 @@ func compileMSVC(cfg dsl.BuildConfig, tc Toolchain, outputPath string) []string
argv := []string{tc.Binary, "/nologo"} argv := []string{tc.Binary, "/nologo"}
if cfg.Standard != "" { if cfg.Standard != "" {
switch cfg.Standard {
case "c11":
cfg.Standard = "c17"
case "c23":
cfg.Standard = "clatest"
case "c++23":
cfg.Standard = "c++23preview"
}
argv = append(argv, "/std:"+cfg.Standard) argv = append(argv, "/std:"+cfg.Standard)
} }