Commit ddd8b56d authored by tzik's avatar tzik Committed by Commit Bot

Disable [[nodiscard]] in STL methods on cl.exe

https://crrev.com/8f14a9d0b7c593e0 enabled opt-in [[nodiscard]] on STL
on Windows build, however, it's unavailable on cl.exe in C++14 mode.
https://ci.chromium.org/buildbot/chromium.fyi/WinMSVC64%20Goma%20Canary/7727

This CL disables it back on cl.exe.

Bug: 852240
Change-Id: Ibfda257eadd6e188f7baa0472785bd3092e76600
Reviewed-on: https://chromium-review.googlesource.com/1100602Reviewed-by: default avatarNico Weber <thakis@chromium.org>
Commit-Queue: Nico Weber <thakis@chromium.org>
Cr-Commit-Position: refs/heads/master@{#567235}
parent 7c8cd0bf
......@@ -1479,8 +1479,10 @@ config("chromium_code") {
if (is_win) {
cflags = [ "/W4" ] # Warning level 4.
# Opt in to additional [[nodiscard]] on standard library methods.
defines = [ "_HAS_NODISCARD" ]
if (is_clang) {
# Opt in to additional [[nodiscard]] on standard library methods.
defines = [ "_HAS_NODISCARD" ]
}
} else {
cflags = [ "-Wall" ]
if (treat_warnings_as_errors) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment