Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: aa23ef2c5affd80b4c8e509d62ff328af934c4a5
      
https://github.com/WebKit/WebKit/commit/aa23ef2c5affd80b4c8e509d62ff328af934c4a5
  Author: Claudio Saavedra <[email protected]>
  Date:   2026-09-30 (Wed, 30 Sep 2026)

  Changed paths:
    M Tools/Scripts/analyze-safer-cpp
    M Tools/Scripts/build-and-analyze
    M Tools/Scripts/webkitpy/safer_cpp/analyze_safer_cpp_unittest.py
    M Tools/Scripts/webkitpy/safer_cpp/checkers.py

  Log Message:
  -----------
  Take the Safer C++ checker list and the checkout root from webkitpy
https://bugs.webkit.org/show_bug.cgi?id=325802

Reviewed by Ryosuke Niwa.

build-and-analyze and analyze-safer-cpp each carried a copy of the
checker list and of the analyzer categories to disable, and the copies
had drifted: analyze-safer-cpp lacked UncheckedLambdaCapturesChecker
and listed the three Unborrowed checkers, which are in neither the
registry nor build-and-analyze. The registry in
webkitpy/safer_cpp/checkers.py already names every checker, so give
each entry its analyzer package (alpha.webkit or webkit), derive the
full names from it, and keep the disabled categories next to it. Both
scripts import those instead, and the FIXME about clang-tidy's bugprone
checkers moves next to the categories. build-and-analyze's flags are
unchanged.

analyze-safer-cpp now runs the registry's checkers by default, so it
gains UncheckedLambdaCapturesChecker, which it drops when the toolchain
lacks it as before, and no longer runs the Unborrowed checkers by
default. --checker accepts any alpha.webkit.* or webkit.* name, so they
can still be requested explicitly. They stay out of the registry for
now: an entry there is also an expectations file and an option of
update-safer-cpp-expectations, and clang's call-args and local-vars
borrow checkers report the same bug type, which the description lookup
in generate-dirty-files cannot tell apart.

The checkout root comes from webkitpy's Git.find_checkout_root() rather
than a local git invocation.

* Tools/Scripts/analyze-safer-cpp:
(find_webkit_root):
(normalize_checkers):
* Tools/Scripts/build-and-analyze:
(make_analyzer_flags):
* Tools/Scripts/webkitpy/safer_cpp/analyze_safer_cpp_unittest.py:
(AnalyzeSaferCppCheckerOptionTest):
(AnalyzeSaferCppCheckerOptionTest.test_unlisted_alpha_webkit_checker_is_passed_through):
* Tools/Scripts/webkitpy/safer_cpp/checkers.py:
(Checker.__init__):
(Checker.analyzer_name):
(Checker.analyzer_names):

Canonical link: https://commits.webkit.org/322287@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications

Reply via email to