[all-commits] [llvm/llvm-project] c22719: Make clang-format fuzz through Lexing with asserts...

r4nt via All-commits all-commits at lists.llvm.org
Fri Nov 19 05:44:26 PST 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c2271926a4fc395e05cf75a8e57c2dfab1f02d3d
      https://github.com/llvm/llvm-project/commit/c2271926a4fc395e05cf75a8e57c2dfab1f02d3d
  Author: Manuel Klimek <klimek at google.com>
  Date:   2021-11-19 (Fri, 19 Nov 2021)

  Changed paths:
    M clang/lib/Format/Format.cpp
    M clang/lib/Format/QualifierAlignmentFixer.cpp
    M clang/lib/Format/SortJavaScriptImports.cpp
    M clang/lib/Format/TokenAnalyzer.cpp
    M clang/lib/Format/TokenAnalyzer.h

  Log Message:
  -----------
  Make clang-format fuzz through Lexing with asserts enabled.

Makes clang-format bail out if an in-memory source file with an
unsupported BOM is handed in instead of creating source locations that
are violating clang's assumptions.

In the future, we should add support to better transport error messages
like this through clang-format instead of printing to stderr and not
creating any changes.




More information about the All-commits mailing list