Skip to content

Commit

Permalink
Enable -Wconversion tree-wide on darwin.
Browse files Browse the repository at this point in the history
  • Loading branch information
bzbarsky-apple committed Feb 28, 2023
1 parent 92d86d5 commit 34d7456
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 3 deletions.
4 changes: 4 additions & 0 deletions build/config/compiler/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,10 @@ config("strict_warnings") {
]
}

if (current_os == "mac" || current_os == "ios") {
cflags += [ "-Wconversion" ]
}

if (build_java_matter_controller) {
cflags -= [ "-Wshadow" ]
}
Expand Down
5 changes: 4 additions & 1 deletion third_party/boringssl/repo/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,10 @@ import("BUILD.generated.gni")
config("boringssl_config") {
include_dirs = [ "src/include" ]

cflags = [ "-Wno-unused-variable" ]
cflags = [
"-Wno-unused-variable",
"-Wno-conversion",
]

if (is_clang) {
cflags += [ "-Wno-shorten-64-to-32" ]
Expand Down
4 changes: 3 additions & 1 deletion third_party/editline/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@ import("${build_root}/config/compiler/compiler.gni")
config("editline_config") {
include_dirs = [ "repo/include" ]

cflags = [ "-Wno-conversion" ]

if (is_clang) {
cflags = [ "-Wno-shorten-64-to-32" ]
cflags += [ "-Wno-shorten-64-to-32" ]
}
}

Expand Down
4 changes: 3 additions & 1 deletion third_party/nlunit-test/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@ import("${build_root}/config/compiler/compiler.gni")
config("nlunit-test_config") {
include_dirs = [ "repo/src" ]

cflags = [ "-Wno-conversion" ]

if (is_clang) {
cflags = [ "-Wno-shorten-64-to-32" ]
cflags += [ "-Wno-shorten-64-to-32" ]
}
}

Expand Down

0 comments on commit 34d7456

Please sign in to comment.