[clang-tools-extra] [clang-tidy] Add `-std` argument in `check_clang_tidy.py` for C files (PR #150791)

2025-08-20 Thread Nicolas van Kempen via cfe-commits
@@ -374,15 +373,23 @@ def parse_arguments() -> Tuple[argparse.Namespace, List[str]]: parser.add_argument( "-std", type=csv, -default=["c++11-or-later"], +default=None, help="Passed to clang. Special -or-later values are expanded.",

[clang-tools-extra] [clang-tidy][NFC] Do less unnecessary work in `NoLintDirectiveHandler` (PR #147553)

2025-08-09 Thread Nicolas van Kempen via cfe-commits
@@ -31,8 +31,6 @@ class NoLintDirectiveHandler { public: NoLintDirectiveHandler(); ~NoLintDirectiveHandler(); nicovank wrote: This destructor being explicit also makes the class non-movable. It's `= default;` anyway. (Also needs a change in `.cpp`.) ```s

[clang-tools-extra] [NFC][run-clang-tidy] Add minor type hints (PR #151873)

2025-08-03 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank closed https://github.com/llvm/llvm-project/pull/151873 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NFC][run-clang-tidy] Add minor type hints (PR #151873)

2025-08-03 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: Unfortunately there is no CI setup for this. https://github.com/llvm/llvm-project/pull/151873 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NFC][run-clang-tidy] Add minor type hints (PR #151873)

2025-08-03 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank created https://github.com/llvm/llvm-project/pull/151873 This script passes ``` python3 -m mypy --strict clang-tools-extra/clang-tidy/tool/run-clang-tidy.py ``` `args` and `kwargs` can be typed with what we expect for a single argument. In this case, since we forwa

[clang-tools-extra] [clang-tidy] Add 'enable-check-profiling' with aggregated results to 'run-clang-tidy' (PR #151011)

2025-07-28 Thread Nicolas van Kempen via cfe-commits
@@ -178,6 +182,122 @@ def merge_replacement_files(tmpdir: str, mergefile: str) -> None: open(mergefile, "w").close() +def aggregate_profiles(profile_dir: str) -> Dict[str, float]: +"""Aggregate timing data from multiple profile JSON files""" +aggregated: Dict

[clang-tools-extra] [clang-tidy] Add 'enable-check-profiling' with aggregated results to 'run-clang-tidy' (PR #151011)

2025-07-28 Thread Nicolas van Kempen via cfe-commits
@@ -489,6 +616,12 @@ async def main() -> None: export_fixes_dir = tempfile.mkdtemp() delete_fixes_dir = True +profile_dir: Optional[str] = None +delete_profile_dir = False nicovank wrote: Maybe get rid of `delete_profile_dir` and just

[clang-tools-extra] [clang-tidy] Add 'enable-check-profiling' with aggregated results to 'run-clang-tidy' (PR #151011)

2025-07-28 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: Funny, I wrote this feature a while ago and never got around to making a PR out of it. FWIW here is my (old) diff: https://github.com/llvm/llvm-project/compare/main...nicovank:llvm-project:temporary-tidy-profiles https://github.com/llvm/llvm-project/pull/151011 ___

[clang-tools-extra] [clang-tidy] Add `-std` argument in `check_clang_tidy.py` for C files (PR #150791)

2025-07-26 Thread Nicolas van Kempen via cfe-commits
@@ -374,15 +373,25 @@ def parse_arguments() -> Tuple[argparse.Namespace, List[str]]: parser.add_argument( "-std", type=csv, -default=["c++11-or-later"], +default=None, help="Passed to clang. Special -or-later values are expanded.",

[clang-tools-extra] [clang-tidy][NFC] Enable 'performance-move-const-arg' in '.clang-tidy' config (PR #148549)

2025-07-17 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: > However, from author's point of view, he intended not to use that data > anymore so he used std::move to "semantically" flag it. I'm more in favor of > preserving "semantics" so put CheckTriviallyCopyableMove to false. Adding that keeping `std::move` is robust in cases when t

[clang-tools-extra] [clang-tidy][NFC] add '.clang-tidy' config for clang-tidy project (PR #147793)

2025-07-09 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. https://github.com/llvm/llvm-project/pull/147793 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy][NFC] add '.clang-tidy' config for clang-tidy project (PR #147793)

2025-07-09 Thread Nicolas van Kempen via cfe-commits
@@ -909,10 +909,12 @@ static bool areExprsSameMacroOrLiteral(const BinaryOperator *BinOp, // Left is macro so right macro too if (Rsr.getBegin().isMacroID()) { // Both sides are macros so they are same macro or literal - const llvm::StringRef L = Lexer::getS

[clang] [clang-tools-extra] [ASTMatchers][NFC] Replace `makeMatcher` function with CTAD (PR #147197)

2025-07-06 Thread Nicolas van Kempen via cfe-commits
@@ -672,12 +672,7 @@ class Matcher { DynTypedMatcher Implementation; }; // class Matcher -/// A convenient helper for creating a Matcher without specifying -/// the template type argument. -template -inline Matcher makeMatcher(MatcherInterface *Implementation) { - return

[clang] [clang-tools-extra] [ASTMatchers][NFC] Replace `makeMatcher` function with CTAD (PR #147197)

2025-07-06 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. Looks reasonable to me, thanks! Let's wait for one more set of eyes. I did a quick search for this on GitHub, most hits seem to be in LLVM forks/clones, so it doesn't seem this will impact users (good to check even if internal code). http

[clang] [clang-tools-extra] [ASTMatchers][NFC] Replace `makeMatcher` function with CTAD (PR #147197)

2025-07-06 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank edited https://github.com/llvm/llvm-project/pull/147197 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy][NFC] run clang-format over clang-tidy checks and tool code. (PR #143324)

2025-06-08 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: You're right -- it's already being run, but only on the changed lines, not the entire file. Either way, it should cover future diffs minus rare weird edge cases. https://github.com/llvm/llvm-project/pull/143324 ___ cfe-commits mailing

[clang-tools-extra] [clang-tidy][NFC] run clang-format over clang-tidy checks and tool code. (PR #143324)

2025-06-08 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. LGTM! Can confirm that all `.cpp` and `.h` files in `clang-tools-extra/clang-tidy` pass under `clang-format` head. Maybe this can be added to some formatter CI? I'm not familiar with the CI setup. https://github.com/llvm/llvm-project/pull

[clang-tools-extra] [clang-tidy][NFC] Refactor `modernize-use-trailing-return-type-check` check code and tests (PR #140759)

2025-05-21 Thread Nicolas van Kempen via cfe-commits
@@ -39,23 +38,6 @@ class UseTrailingReturnTypeCheck : public ClangTidyCheck { private: Preprocessor *PP = nullptr; nicovank wrote: Is this field still needed now? https://github.com/llvm/llvm-project/pull/140759

[clang-tools-extra] [clang-tidy][NFC] Refactor `modernize-use-trailing-return-type-check` check code and tests (PR #140759)

2025-05-20 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank edited https://github.com/llvm/llvm-project/pull/140759 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy][NFC] Refactor `modernize-use-trailing-return-type-check` check code and tests (PR #140759)

2025-05-20 Thread Nicolas van Kempen via cfe-commits
@@ -28,7 +27,7 @@ struct ClassifiedToken { class UseTrailingReturnTypeCheck : public ClangTidyCheck { public: UseTrailingReturnTypeCheck(StringRef Name, ClangTidyContext *Context) - : ClangTidyCheck(Name, Context) {} + : ClangTidyCheck(Name, Context) {}; ---

[clang-tools-extra] [CLANGD] [NFC] Fix proposed by sanitizer. (PR #140116)

2025-05-15 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. LGTM! AFAICT in this case this won't make an immediate performance difference since fields in this struct are primitives, but may in the future if the struct changes. This probably won't trigger [performance-move-const-arg](https://clang

[clang-tools-extra] Fix spelling error crtp-constructor-accessibility.rst (PR #139307)

2025-05-10 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: Thank you! https://github.com/llvm/llvm-project/pull/139307 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] Fix spelling error crtp-constructor-accessibility.rst (PR #139307)

2025-05-10 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank closed https://github.com/llvm/llvm-project/pull/139307 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] Fix spelling error crtp-constructor-accessibility.rst (PR #139307)

2025-05-10 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. https://github.com/llvm/llvm-project/pull/139307 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NFC] Fix potential nullptr dereference. (PR #138283)

2025-05-02 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: > But it might not be a `UnaryOperator`, no? `unaryOperator(...).bind("op")` implies `op` will always be a `UnaryOperator`. https://github.com/llvm/llvm-project/pull/138283 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https:

[clang-tools-extra] [NFC] Fix potential nullptr dereference. (PR #138283)

2025-05-02 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank requested changes to this pull request. This is not needed IMO. This is a simple matcher, `op` is expected to always be bound. One might say that it can't hurt to add extra checks, but I don't think that's good justification for adding more code / bloat, even if in

[clang-tools-extra] [clang-tidy][NFC][doc] fix typos in docs. (PR #138305)

2025-05-02 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. https://github.com/llvm/llvm-project/pull/138305 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NFC][clang-tidy] Remove {{^}} clauses in some tests (2/N) (PR #135824)

2025-04-18 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank closed https://github.com/llvm/llvm-project/pull/135824 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NFC][clang-tidy] Remove {{^}} clauses in some tests (3/N) (PR #135826)

2025-04-17 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank closed https://github.com/llvm/llvm-project/pull/135826 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NFC][clang-tidy] Remove {{^}} clauses in some tests (3/N) (PR #135826)

2025-04-15 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank created https://github.com/llvm/llvm-project/pull/135826 `check_clang_tidy` now matches full lines only, so `{{^}}` clauses are no longer necessary. I am splitting those changes over multiple PRs to make review easier. Numbering them but the actual order doesn't m

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-04-07 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank closed https://github.com/llvm/llvm-project/pull/133756 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-04-07 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/133756 >From 3f332176331ff0da2413eae0db9e7f9ce816bbd1 Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Mon, 7 Apr 2025 13:51:59 -0400 Subject: [PATCH] [clang-tidy] Use --match-full-lines instead of --strict-wh

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-04-07 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/133756 >From 3f332176331ff0da2413eae0db9e7f9ce816bbd1 Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Mon, 7 Apr 2025 13:51:59 -0400 Subject: [PATCH] [clang-tidy] Use --match-full-lines instead of --strict-wh

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-04-05 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank created https://github.com/llvm/llvm-project/pull/133756 See Discourse post here: https://discourse.llvm.org/t/rfc-using-match-full-lines-in-clang-tidy-tests/85553 I've added `--match-partial-fixes` to all tests that were failing, unless I noticed the fix was quick

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-04-04 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/133756 >From 79484e3802c16ca2f5d3e8c46b2f8895ce580795 Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Mon, 31 Mar 2025 13:33:10 -0400 Subject: [PATCH] [clang-tidy] Use --match-full-lines instead of --strict-w

[clang-tools-extra] [NFC] Fixes proposed by code sanitizer. (PR #134138)

2025-04-03 Thread Nicolas van Kempen via cfe-commits
@@ -535,7 +535,7 @@ struct FragmentCompiler { } if (Filters->empty()) return std::nullopt; -auto Filter = [Filters](llvm::StringRef Path) { +auto Filter = [Filters = std::move(Filters)](llvm::StringRef Path) { nicovank wrote: Line 520: th

[clang-tools-extra] [NFC] Fixes proposed by code sanitizer. (PR #134138)

2025-04-03 Thread Nicolas van Kempen via cfe-commits
@@ -535,7 +535,7 @@ struct FragmentCompiler { } if (Filters->empty()) return std::nullopt; -auto Filter = [Filters](llvm::StringRef Path) { +auto Filter = [Filters = std::move(Filters)](llvm::StringRef Path) { for (auto &Regex : *Filters) --

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-03-31 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/133756 >From 4df359ed712486c9fc94f1296474cdb06715 Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Mon, 31 Mar 2025 15:16:32 -0400 Subject: [PATCH] [clang-tidy] Use --match-full-lines instead of --strict-w

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-03-31 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/133756 >From 4df359ed712486c9fc94f1296474cdb06715 Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Mon, 31 Mar 2025 15:16:32 -0400 Subject: [PATCH] [clang-tidy] Use --match-full-lines instead of --strict-w

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-03-31 Thread Nicolas van Kempen via cfe-commits
@@ -245,15 +246,15 @@ def check_no_diagnosis(self, clang_tidy_output: str) -> None: def check_fixes(self) -> None: if self.has_check_fixes: -try_run( -[ -"FileCheck", -"-input-file=" + self.temp_f

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-03-31 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/133756 >From 79484e3802c16ca2f5d3e8c46b2f8895ce580795 Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Mon, 31 Mar 2025 13:33:10 -0400 Subject: [PATCH] [clang-tidy] Use --match-full-lines instead of --strict-w

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-03-31 Thread Nicolas van Kempen via cfe-commits
@@ -172,7 +172,7 @@ void test(std::string s, std::string_view sv, sub_string ss, sub_sub_string sss, 0 != s.compare(0, sv.length(), sv); // CHECK-MESSAGES: :[[@LINE-1]]:{{[0-9]+}}: warning: use starts_with - // CHECK-FIXES: s.starts_with(sv); + // CHECK-FIXES: !s.starts

[clang-tools-extra] [clang-tidy] Use --match-full-lines instead of --strict-whitespace in check_clang_tidy (PR #133756)

2025-03-31 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: The main changes are here. https://github.com/llvm/llvm-project/pull/133756 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to check_clang_tidy (PR #133140)

2025-03-30 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank closed https://github.com/llvm/llvm-project/pull/133140 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to check_clang_tidy (PR #133140)

2025-03-27 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/133140 >From 48bb3c79069c9bad5ee01865058a155368586b2e Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Thu, 27 Mar 2025 13:28:56 -0400 Subject: [PATCH] [NFC][clang-tidy] Add type annotations to check_clang_tidy

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to check_clang_tidy (PR #133140)

2025-03-27 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/133140 >From 6d0068c97341a93ee116878599c13e429082b0a8 Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Thu, 27 Mar 2025 13:35:05 -0400 Subject: [PATCH] [NFC][clang-tidy] Add type annotations to check_clang_tidy

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to check_clang_tidy (PR #133140)

2025-03-27 Thread Nicolas van Kempen via cfe-commits
@@ -71,12 +72,13 @@ def try_run(args, raise_error=True): # This class represents the appearance of a message prefix in a file. class MessagePrefix: -def __init__(self, label): + nicovank wrote: Note that this space is "on purpose", the formatter wants it

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to check_clang_tidy (PR #133140)

2025-03-27 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/133140 >From 6d0068c97341a93ee116878599c13e429082b0a8 Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Thu, 27 Mar 2025 13:35:05 -0400 Subject: [PATCH] [NFC][clang-tidy] Add type annotations to check_clang_tidy

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to check_clang_tidy (PR #133140)

2025-03-27 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank edited https://github.com/llvm/llvm-project/pull/133140 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to check_clang_tidy (PR #133140)

2025-03-27 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank updated https://github.com/llvm/llvm-project/pull/133140 >From 48bb3c79069c9bad5ee01865058a155368586b2e Mon Sep 17 00:00:00 2001 From: Nicolas van Kempen Date: Thu, 27 Mar 2025 13:28:56 -0400 Subject: [PATCH] [NFC][clang-tidy] Add type annotations to check_clang_tidy

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to check_clang_tidy (PR #133140)

2025-03-27 Thread Nicolas van Kempen via cfe-commits
@@ -48,15 +48,16 @@ import re import subprocess import sys +from typing import List, Tuple nicovank wrote: `list` and `tuple` are Python 3.9: https://peps.python.org/pep-0585/ LLVM minimum Python version is 3.8 for now: https://github.com/llvm/llvm-project/bl

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to check_clang_tidy (PR #133140)

2025-03-27 Thread Nicolas van Kempen via cfe-commits
@@ -71,12 +72,12 @@ def try_run(args, raise_error=True): # This class represents the appearance of a message prefix in a file. class MessagePrefix: -def __init__(self, label): +def __init__(self, label: str): nicovank wrote: Good catch, thank you, I a

[clang-tools-extra] [NFC][clang-tidy] Add type annotations to check_clang_tidy (PR #133140)

2025-03-26 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank created https://github.com/llvm/llvm-project/pull/133140 I'm looking to make some changes in this file, start by typing it. ``` > python3 -m mypy --strict clang-tools-extra/test/clang-tidy/check_clang_tidy.py Success: no issues found in 1 source file ``` >From ba5

[clang-tools-extra] [clang-tidy] 'modernize-use-starts-ends-with': fixed false positives on `find` and `rfind` (PR #129564)

2025-03-22 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: Thanks! https://github.com/llvm/llvm-project/pull/129564 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] 'modernize-use-starts-ends-with': fixed false positives on `find` and `rfind` (PR #129564)

2025-03-22 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank closed https://github.com/llvm/llvm-project/pull/129564 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] 'modernize-use-starts-ends-with': fixed false positives on `find` and `rfind` (PR #129564)

2025-03-13 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. I saw you have a pending commit access request -- I'll just let you merge this when you are able to. https://github.com/llvm/llvm-project/pull/129564 ___ cfe-commits mailing list cfe-commits@list

[clang-tools-extra] [clang-tidy] 'modernize-use-starts-ends-with': fixed false positives on `find` and `rfind` (PR #129564)

2025-03-05 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. LGTM, thanks!! https://github.com/llvm/llvm-project/pull/129564 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] 'modernize-use-starts-ends-with': fixed false positives on `find` and `rfind` (PR #129564)

2025-03-05 Thread Nicolas van Kempen via cfe-commits
@@ -128,7 +128,12 @@ Changes in existing checks ` check by providing additional examples and fixing some macro related false positives. -- Improved :doc:`performance/unnecessary-value-param +- Improved :doc:`modernize-use-starts-ends-with + ` check by adding more + match

[clang-tools-extra] [clang-tidy] 'modernize-use-starts-ends-with': fixed false positives on `find` and `rfind` (PR #129564)

2025-03-05 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank edited https://github.com/llvm/llvm-project/pull/129564 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-02-20 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank edited https://github.com/llvm/llvm-project/pull/105893 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-02-20 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank edited https://github.com/llvm/llvm-project/pull/105893 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-02-20 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,788 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-02-20 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,788 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-02-20 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,788 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-02-20 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,788 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-02-20 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,788 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [clang-tidy] Add support for `-ignore-insert-conflict` in `run-clang-tidy.py` (PR #127066)

2025-02-15 Thread Nicolas van Kempen via cfe-commits
Vicente Mataix =?utf-8?q?Ferrándiz?= , Vicente Mataix =?utf-8?q?Ferrándiz?= , Vicente Mataix =?utf-8?q?Ferrándiz?= Message-ID: In-Reply-To: @@ -446,6 +448,12 @@ async def main() -> None: action="store_true", help="Allow empty enabled checks.", ) +pars

[clang-tools-extra] [clang-tidy] Refactor: removed typos in 'AllowedTypes' option in various checks (PR #122957)

2025-01-29 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank closed https://github.com/llvm/llvm-project/pull/122957 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Refactor: removed typos in 'AllowedTypes' option in various checks (PR #122957)

2025-01-28 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. LGTM. Thanks! https://github.com/llvm/llvm-project/pull/122957 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Refactor: removed typos in 'AllowedTypes' option in various checks (PR #122957)

2025-01-28 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank edited https://github.com/llvm/llvm-project/pull/122957 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Refactor: removed typos in 'AllowedTypes' option in various checks (PR #122957)

2025-01-27 Thread Nicolas van Kempen via cfe-commits
@@ -31,6 +31,6 @@ Options A semicolon-separated list of names of types allowed to be copied in each iteration. Regular expressions are accepted, e.g. `[Rr]ef(erence)?$` matches every type with suffix `Ref`, `ref`, `Reference` and `reference`. The default -

[clang-tools-extra] [clang-tidy] Refactor: removed typos in 'AllowedTypes' option in various checks (PR #122957)

2025-01-27 Thread Nicolas van Kempen via cfe-commits
@@ -31,6 +31,6 @@ Options A semicolon-separated list of names of types allowed to be copied in each iteration. Regular expressions are accepted, e.g. `[Rr]ef(erence)?$` matches every type with suffix `Ref`, `ref`, `Reference` and `reference`. The default -

[clang-tools-extra] [clang-tidy] Refactor: removed typos in 'AllowedTypes' option in various checks (PR #122957)

2025-01-27 Thread Nicolas van Kempen via cfe-commits
@@ -31,6 +31,6 @@ Options A semicolon-separated list of names of types allowed to be copied in each iteration. Regular expressions are accepted, e.g. `[Rr]ef(erence)?$` matches every type with suffix `Ref`, `ref`, `Reference` and `reference`. The default -

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-14 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank commented: Some comments. Regarding usage of `std::string`: Right now the library takes a `StringRef` through `Template` and `Parser`, and then keeps (2-4?) copies of chunks of the input in `Token` (`RawBody` and `TokenBody`) then `ASTNode` (`RawBody` and `Body`).

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,114 @@ +//===--- Mustache.h -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: I might have missed it but test re-using `Template` and rendering twice? https://github.com/llvm/llvm-project/pull/105893 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank edited https://github.com/llvm/llvm-project/pull/105893 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,114 @@ +//===--- Mustache.h -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank edited https://github.com/llvm/llvm-project/pull/105893 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,114 @@ +//===--- Mustache.h -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,114 @@ +//===--- Mustache.h -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,114 @@ +//===--- Mustache.h -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,114 @@ +//===--- Mustache.h -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,114 @@ +//===--- Mustache.h -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,785 @@ +//===-- Mustache.cpp --===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-13 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,114 @@ +//===--- Mustache.h -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [llvm] [llvm] add support for mustache templating language (PR #105893)

2025-01-09 Thread Nicolas van Kempen via cfe-commits
@@ -0,0 +1,114 @@ +//===--- Mustache.h -*- C++ -*-===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Ap

[clang-tools-extra] [clang-tidy] fix incorrect argument names in documentation for ExtraArgs and ExtraArgsBefore (PR #120963)

2024-12-24 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. LGTM, thanks! https://github.com/llvm/llvm-project/pull/120963 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] fix incorrect argument names in documentation for ExtraArgs and ExtraArgsBefore (PR #120963)

2024-12-23 Thread Nicolas van Kempen via cfe-commits
nicovank wrote: Sync with [ClangTidyMain.cpp](https://github.com/llvm/llvm-project/blob/d36836de0183b9b1939cc679d153e3b313e55c76/clang-tools-extra/clang-tidy/tool/ClangTidyMain.cpp#L57-L58)? https://github.com/llvm/llvm-project/blob/d36836de0183b9b1939cc679d153e3b313e55c76/clang-tools-extra/cla

[clang-tools-extra] [clang-tidy][doc] align the title style in clang-tidy/index.rst (PR #119938)

2024-12-13 Thread Nicolas van Kempen via cfe-commits
@@ -9,7 +9,7 @@ See also: .. toctree:: :maxdepth: 1 - The list of clang-tidy checks + The List of Clang-Tidy Checks nicovank wrote: Maybe? ```suggestion List of Clang-Tidy Checks ``` https://github.com/llvm/llvm-project/pull/119938

[clang-tools-extra] [clang-tidy][doc] align the title style in clang-tidy/index.rst (PR #119938)

2024-12-13 Thread Nicolas van Kempen via cfe-commits
https://github.com/nicovank approved this pull request. Ctrl+F -ing for lowercase `clang-tidy` reveals a couple more places where it should maybe be updated: lines 331, 350 and 352 (`` :program:`clang-tidy` ``?). It's very minor anyway. https://github.com/llvm/llvm-project/pull/119938

  1   2   3   4   5   >