commit 973c1d7f9b0fa67c119e95013bdefdfe32c2d563 parent 19605c67c4ff06e4b4904c1a919a289b8dcc3647 Author: André Bargull <andre.bargull@gmail.com> Date: Wed, 17 Dec 2025 13:42:06 +0000 Bug 2002522 - Part 4: Enable warnings for js/src. r=spidermonkey-reviewers,jandem Enable these warnings to avoid regressions. Differential Revision: https://phabricator.services.mozilla.com/D274124 Diffstat:
| M | js/src/js-cxxflags.mozbuild | | | 10 | ++++++++++ |
1 file changed, 10 insertions(+), 0 deletions(-)
diff --git a/js/src/js-cxxflags.mozbuild b/js/src/js-cxxflags.mozbuild @@ -16,3 +16,13 @@ if CONFIG["CC_TYPE"] in ("clang", "gcc"): # https://gcc.gnu.org/bugzilla/show_bug.cgi?id=50044 if CONFIG["CC_TYPE"] == "gcc": CXXFLAGS += ["-Wno-attributes"] + +# Override definitions from "build/moz.configure/warnings.configure" until +# these warnings are enabled by default. +# +# (Older) GCC doesn't support these warnings, so only enable when compiling +# with Clang. +if CONFIG["CC_TYPE"] in ("clang", "clang-cl"): + CXXFLAGS += ["-Wdeprecated-this-capture"] + CXXFLAGS += ["-Wdeprecated-anon-enum-enum-conversion"] + CXXFLAGS += ["-Wdeprecated-enum-enum-conversion"]