[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-02-06 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/78752 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-02-06 Thread via cfe-commits
j-jorge wrote: Hey, now that the PR has been reviewed, approved, and all checked as passed, do I have something else to do to have it merged? https://github.com/llvm/llvm-project/pull/78752 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-22 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request. https://github.com/llvm/llvm-project/pull/78752 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-22 Thread via cfe-commits
https://github.com/j-jorge updated https://github.com/llvm/llvm-project/pull/78752 >From b6284b7498a283d28bfd5025897041dee23354c8 Mon Sep 17 00:00:00 2001 From: Julien Jorge Date: Fri, 19 Jan 2024 18:44:58 +0100 Subject: [PATCH] [clang-format] Add MainIncludeChar option. Resolves #27008, #3973

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-22 Thread Kazu Hirata via cfe-commits
https://github.com/kazutakahirata updated https://github.com/llvm/llvm-project/pull/78752 >From b6284b7498a283d28bfd5025897041dee23354c8 Mon Sep 17 00:00:00 2001 From: Julien Jorge Date: Fri, 19 Jan 2024 18:44:58 +0100 Subject: [PATCH] [clang-format] Add MainIncludeChar option. Resolves #27008

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-21 Thread via cfe-commits
@@ -0,0 +1,27 @@ +// Test the combination of regrouped include directives, via regexes and j-jorge wrote: Done. https://github.com/llvm/llvm-project/pull/78752 ___ cfe-commits mailing list cfe-commits@lists.llvm.org ht

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-21 Thread via cfe-commits
@@ -151,6 +151,21 @@ struct IncludeStyle { /// before any other include. /// \version 10 std::string IncludeIsMainSourceRegex; + + /// Character to consider in the include directives for the main header. j-jorge wrote: Done. https://github.com/llvm/llv

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-21 Thread via cfe-commits
@@ -151,6 +151,21 @@ struct IncludeStyle { /// before any other include. /// \version 10 std::string IncludeIsMainSourceRegex; + + /// Character to consider in the include directives for the main header. + enum MainIncludeCharDiscriminator { j-jorge wro

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-21 Thread via cfe-commits
@@ -3392,6 +3392,24 @@ the configuration (without a prefix: ``Auto``). Priority:1 SortPriority:0 +.. _MainIncludeChar: j-jorge wrote: Done. https://github.com/llvm/llvm-project/pull/78752 __

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-21 Thread via cfe-commits
@@ -151,6 +151,21 @@ struct IncludeStyle { /// before any other include. /// \version 10 std::string IncludeIsMainSourceRegex; + + /// Character to consider in the include directives for the main header. + enum MainIncludeCharDiscriminator { +/// Main include uses q

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-21 Thread via cfe-commits
https://github.com/j-jorge updated https://github.com/llvm/llvm-project/pull/78752 >From 6561598bff3401eb5a523f32f29c6be250e27a97 Mon Sep 17 00:00:00 2001 From: Julien Jorge Date: Fri, 19 Jan 2024 18:44:58 +0100 Subject: [PATCH] [clang-format] Add MainIncludeChar option. Resolves #27008, #3973

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-21 Thread via cfe-commits
https://github.com/j-jorge updated https://github.com/llvm/llvm-project/pull/78752 >From 7e06f6b5c5f5a156ce01a8fe219b8f5b6b8c9a24 Mon Sep 17 00:00:00 2001 From: Julien Jorge Date: Fri, 19 Jan 2024 18:44:58 +0100 Subject: [PATCH] [clang-format] Add MainIncludeChar option. Resolves #27008, #3973

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-20 Thread Owen Pan via cfe-commits
@@ -0,0 +1,27 @@ +// Test the combination of regrouped include directives, via regexes and owenca wrote: > Ok I will move them there, thanks :) Should I remove these lit tests or are > they complementary? Please remove them from the lit tests. https://github.c

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-20 Thread Björn Schäpers via cfe-commits
@@ -0,0 +1,27 @@ +// Test the combination of regrouped include directives, via regexes and HazardyKnusperkeks wrote: I've never run anything but the unit tests. I'd remove these, but I have no strong opinion on that matter. https://github.com/llvm/llvm-project/

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-20 Thread Björn Schäpers via cfe-commits
@@ -3392,6 +3392,24 @@ the configuration (without a prefix: ``Auto``). Priority:1 SortPriority:0 +.. _MainIncludeChar: HazardyKnusperkeks wrote: There's a script: `clang/doc/tools/dump_format_style.py`. https://github.com/llvm/llv

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread via cfe-commits
@@ -0,0 +1,27 @@ +// Test the combination of regrouped include directives, via regexes and j-jorge wrote: Ok I will move them there, thanks :) Should I remove these lit tests or are they complementary? https://github.com/llvm/llvm-project/pull/78752 ___

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread via cfe-commits
@@ -3392,6 +3392,24 @@ the configuration (without a prefix: ``Auto``). Priority:1 SortPriority:0 +.. _MainIncludeChar: j-jorge wrote: Yes, is it supposed to be automatically generated? https://github.com/llvm/llvm-project/pull/787

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread Björn Schäpers via cfe-commits
@@ -151,6 +151,21 @@ struct IncludeStyle { /// before any other include. /// \version 10 std::string IncludeIsMainSourceRegex; + + /// Character to consider in the include directives for the main header. HazardyKnusperkeks wrote: It should also be added

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread Björn Schäpers via cfe-commits
@@ -0,0 +1,27 @@ +// Test the combination of regrouped include directives, via regexes and HazardyKnusperkeks wrote: Our tests reside in `clang/unittests/Format/SortIncludesTest.cpp`. https://github.com/llvm/llvm-project/pull/78752 __

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread Björn Schäpers via cfe-commits
@@ -151,6 +151,21 @@ struct IncludeStyle { /// before any other include. /// \version 10 std::string IncludeIsMainSourceRegex; + + /// Character to consider in the include directives for the main header. + enum MainIncludeCharDiscriminator { HazardyKnus

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread Björn Schäpers via cfe-commits
@@ -151,6 +151,21 @@ struct IncludeStyle { /// before any other include. /// \version 10 std::string IncludeIsMainSourceRegex; + + /// Character to consider in the include directives for the main header. + enum MainIncludeCharDiscriminator { +/// Main include uses q

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks edited https://github.com/llvm/llvm-project/pull/78752 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread Björn Schäpers via cfe-commits
@@ -3392,6 +3392,24 @@ the configuration (without a prefix: ``Auto``). Priority:1 SortPriority:0 +.. _MainIncludeChar: HazardyKnusperkeks wrote: Did you add this by hand? I'm wondering why it has a different order than in the head

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks requested changes to this pull request. https://github.com/llvm/llvm-project/pull/78752 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread via cfe-commits
https://github.com/j-jorge updated https://github.com/llvm/llvm-project/pull/78752 >From 11c7a60c5487d01e49b113bc264bb166d6df5457 Mon Sep 17 00:00:00 2001 From: Julien Jorge Date: Fri, 19 Jan 2024 18:44:58 +0100 Subject: [PATCH] [clang-format] Add MainIncludeChar option. Resolves #27008, #3973

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff b6677835fed3a204fa043e079a135c4a225d2c0e db59f23f7dff603b00c40761c8fa935876b1654b --

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (j-jorge) Changes Resolves #27008, #39735, #53013, #63619. Hello, this PR adds the MainIncludeChar option to clang-format, allowing to select which include syntax must be considered when searching for the main header: quotes (`#incl

[clang] [clang-format] Add MainIncludeChar option. (PR #78752)

2024-01-19 Thread via cfe-commits
https://github.com/j-jorge created https://github.com/llvm/llvm-project/pull/78752 Resolves #27008, #39735, #53013, #63619. Hello, this PR adds the MainIncludeChar option to clang-format, allowing to select which include syntax must be considered when searching for the main header: quotes (`#