[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-12-19 Thread kleines Filmröllchen via cfe-commits
kleinesfilmroellchen wrote: I don't have any energy and the massive reachitecting requested would take me tons of time. Please adopt this. Serenity folks are also waiting fwiw https://github.com/llvm/llvm-project/pull/67749 ___ cfe-commits mailing lis

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-01-26 Thread kleines Filmröllchen via cfe-commits
kleinesfilmroellchen wrote: > Sorry, I'm still struggling with Github reviews compared to Phabricator... > how do I get to an interdiff showing the latest version of the patch compared > to the version I reviewed? I'm fairly sure that GitHub has no built-in feature for this; I've never used i

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-01-25 Thread kleines Filmröllchen via cfe-commits
kleinesfilmroellchen wrote: > It's sad that there's not a single codepath that would handle all these, but > maybe the perfect is the enemy of the good here. The code duplication was my reason for looking at the common path. If you're fine with duplicating the code I will go ahead and do that.

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-01-25 Thread kleines Filmröllchen via cfe-commits
https://github.com/kleinesfilmroellchen updated https://github.com/llvm/llvm-project/pull/67749 From 67971ca27ef5e2767aba5cfe2cec1021c4de5ec1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?kleines=20Filmr=C3=B6llchen?= Date: Thu, 25 Jan 2024 18:04:35 +0100 Subject: [PATCH] [clangd] Allow specifying w

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-01-25 Thread kleines Filmröllchen via cfe-commits
kleinesfilmroellchen wrote: > It's sad that there's not a single codepath that would handle all these, but > maybe the perfect is the enemy of the good here. The code duplication was my reason for looking at the common path. If you're fine with duplicating the code I will go ahead and do that.

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-01-25 Thread kleines Filmröllchen via cfe-commits
@@ -211,10 +214,12 @@ class IncludeInserter { // include path of non-verbatim header will not be shortened. IncludeInserter(StringRef FileName, StringRef Code, const format::FormatStyle &Style, StringRef BuildDir, - HeaderSearch *HeaderSea

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-01-25 Thread kleines Filmröllchen via cfe-commits
@@ -296,6 +296,19 @@ struct Fragment { // ::). All nested namespaces are affected as well. // Affects availability of the AddUsing tweak. std::vector> FullyQualifiedNamespaces; + +/// List of regexes for headers that should always be included with a +/// ""-

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-01-22 Thread kleines Filmröllchen via cfe-commits
kleinesfilmroellchen wrote: After some discussion, I would like to land the feature "partially" as-is without support for "include cleaner" header insertion. (Case 3 in @HighCommander4's elaboration above.) This is motivated by two factors: - Having looked at a way of supporting all three inser

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-01-04 Thread kleines Filmröllchen via cfe-commits
https://github.com/kleinesfilmroellchen updated https://github.com/llvm/llvm-project/pull/67749 From 8a2b22e69f82e3f4caa271b57b998d1c03b21d39 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?kleines=20Filmr=C3=B6llchen?= Date: Thu, 4 Jan 2024 11:53:23 +0100 Subject: [PATCH] [clangd] Allow specifying wh

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2024-01-04 Thread kleines Filmröllchen via cfe-commits
kleinesfilmroellchen wrote: > > What is the relationship between this patch, and clangd 17's ["missing > > include" > > warning](https://clangd.llvm.org/guides/include-cleaner#missing-include-warning)? > > Does the quick-fix for the "missing include" warning also respect these > > config opti

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2023-10-11 Thread kleines Filmröllchen via cfe-commits
@@ -483,6 +483,56 @@ struct FragmentCompiler { FullyQualifiedNamespaces.begin(), FullyQualifiedNamespaces.end()); }); } +auto QuotedFilter = compileHeaderRegexes(F.QuotedHeaders); +if (QuotedFilter.has_value()) { + Out.Apply.push_back( +

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2023-10-02 Thread kleines Filmröllchen via cfe-commits
https://github.com/kleinesfilmroellchen updated https://github.com/llvm/llvm-project/pull/67749 From 2e3f397ffc8967fdc13ced1ec0c4a7dc55a2400d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?kleines=20Filmr=C3=B6llchen?= Date: Mon, 2 Oct 2023 17:51:16 +0200 Subject: [PATCH] [clangd] Allow specifying wh

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2023-10-01 Thread kleines Filmröllchen via cfe-commits
kleinesfilmroellchen wrote: Thanks for the finding @zyn0217, refactored the config compiler code a little. Tests should pass now and I have re-tested this on SerenityOS and other small project where it works as expected in practice. https://github.com/llvm/llvm-project/pull/67749 _

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2023-10-01 Thread kleines Filmröllchen via cfe-commits
https://github.com/kleinesfilmroellchen updated https://github.com/llvm/llvm-project/pull/67749 From 167048c7025a516a5e57009947333c3980017107 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?kleines=20Filmr=C3=B6llchen?= Date: Sun, 1 Oct 2023 14:48:57 +0200 Subject: [PATCH] [clangd] Allow specifying wh

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2023-09-30 Thread kleines Filmröllchen via cfe-commits
kleinesfilmroellchen wrote: I investigated the test failures some more in the context of where the bug affects real uses and I'm unsure as to what's going on. ```yaml Style: QuotedHeaders: ["blahblahblah"] AngledHeaders: ["AK/.*", "Userland/.*", "Kernel/.*", "Applications/.*", "Lib.*/.*"] `

[clang-tools-extra] [clangd] Allow specifying what headers are always included via "" or <> (PR #67749)

2023-09-28 Thread kleines Filmröllchen via cfe-commits
https://github.com/kleinesfilmroellchen created https://github.com/llvm/llvm-project/pull/67749 Projects can now add config fragments like this to their .clangd: ```yaml Style: QuotedHeaders: "src/.*" AngledHeaders: ["path/sdk/.*", "third-party/.*"] ``` to force headers inserted via the --