12 Commits

Author SHA1 Message Date
Kazu Hirata
e266d6a5da
[Format] Use llvm::min_element (NFC) (#143725)
llvm::min_elements allows us to pass a range.
2025-06-11 12:50:11 -07:00
Kazu Hirata
23c2f8827b
[Format] Use llvm::count_if (NFC) (#141518) 2025-05-26 19:43:28 -07:00
Kazu Hirata
6d2a7b4546
[clang] Use llvm::find_if (NFC) (#140983) 2025-05-21 20:31:52 -07:00
Kazu Hirata
43829039c9
[Format] Use a range constructor of DenseSet (NFC) (#133382) 2025-03-28 07:52:43 -07:00
Owen Pan
b2082a9817 Revert "[clang-format][NFC] Delete 100+ redundant #include lines in .cpp files"
This reverts commit b92d6dd704d789240685a336ad8b25a9f381b4cc. See
github.com/llvm/llvm-project/commit/b92d6dd704d7#commitcomment-139992444

We should use a tool like Visual Studio to clean up the headers.
2024-03-19 21:28:22 -07:00
Owen Pan
b92d6dd704 [clang-format][NFC] Delete 100+ redundant #include lines in .cpp files 2024-03-16 22:24:11 -07:00
r4nt
ddb4450a46
[ClangFormat] Fix indent in child lines within a macro argument. (#82523)
When reconstructing lines from a macro expansion, make sure that lines
at different levels in the expanded code get indented correctly as part
of the macro argument.
2024-02-23 13:18:00 +01:00
Björn Schäpers
2c3b12b541 [clang-format][NFCish] Obey debug settings
Differential Revision: https://reviews.llvm.org/D156228
2023-08-02 11:50:14 +02:00
serge-sans-paille
a3c248db87
Move from llvm::makeArrayRef to ArrayRef deduction guides - clang/ part
This is a follow-up to https://reviews.llvm.org/D140896, split into
several parts as it touches a lot of files.

Differential Revision: https://reviews.llvm.org/D141139
2023-01-09 12:15:24 +01:00
owenca
3d62139862 [clang-format][NFC] Reformat clang/lib/Format using 6257832bf94f
Fix braces and add .clang-format to keep the directory formatted.

Differential Revision: https://reviews.llvm.org/D134329
2022-09-21 12:02:49 -07:00
Manuel Klimek
f44d28f840 Fix build errors. 2022-07-12 07:43:26 +00:00
Manuel Klimek
d6d0dc1f45 [clang-format] Add MacroUnexpander.
MacroUnexpander applies the structural formatting of expanded lines into
UnwrappedLines to the corresponding unexpanded macro calls, resulting in
UnwrappedLines for the macro calls the user typed.

Differential Revision: https://reviews.llvm.org/D88299
2022-07-12 07:11:46 +00:00