[config] Suppress implicit fallthrough
Change-Id: I12b6976de66a12135aeefa5b8b922f7164938b1f
Reviewed-on: https://fuchsia-review.googlesource.com/c/third_party/expat/+/527266
Reviewed-by: Shai Barack <shayba@google.com>
diff --git a/BUILD.gn b/BUILD.gn
index 3019360..dfc8387 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -8,12 +8,17 @@
"expat/vms",
]
defines = [ "HAVE_EXPAT_CONFIG_H" ]
- # Suppress compiler warnings in dependant targets caused by
- # public headers in expat.
- cflags = [ "-Wno-conversion" ]
+}
+
+config("expat_warnings") {
+ cflags = [
+ "-Wno-conversion",
+ "-Wno-implicit-fallthrough",
+ ]
}
source_set("expat") {
+ configs += [ ":expat_warnings" ]
public_configs = [ ":expat_config" ]
public = [ "expat/lib/expat.h" ]
sources = [