[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2024-02-09 Thread Shafik Yaghmour via cfe-commits
@@ -183,7 +184,7 @@ class ResultBuilder { /// Overloaded C++ member functions found by SemaLookup. /// Used to determine when one overload is dominated by another. - llvm::DenseMap, ShadowMapEntry> + llvm::DenseMap, ShadowMapEntry> shafik wrote:

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2024-02-09 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik edited https://github.com/llvm/llvm-project/pull/75937 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2024-02-09 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik commented: Nit https://github.com/llvm/llvm-project/pull/75937 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2023-12-22 Thread Sirui Mu via cfe-commits
Lancern wrote: > Feel free to put up a PR / issue for this if you are interested. Hi Younan. FYI, I have opened a new PR that addresses this problem. See #76248. https://github.com/llvm/llvm-project/pull/75937 ___ cfe-commits mailing list

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2023-12-19 Thread Younan Zhang via cfe-commits
zyn0217 wrote: > Maybe this deserves a new issue for clang Sema? Sounds reasonable to me. Feel free to put up a PR / issue for this if you are interested. https://github.com/llvm/llvm-project/pull/75937 ___ cfe-commits mailing list

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2023-12-19 Thread Sirui Mu via cfe-commits
Lancern wrote: > The place you're patching is not only specific to "completing override > functions", but handles all completion strings involving function > declarations. OK. I'll move the changes to the `CodeCompletionResult::createCodeCompletionStringForOverride` function which seems

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2023-12-19 Thread Younan Zhang via cfe-commits
zyn0217 wrote: Bonus: It appears that neither gcc nor clang implements a provision change from [CWG1351](https://cplusplus.github.io/CWG/issues/1351.html), > [except.spec]p4 > ..., **unless the overriding function is defined as deleted.** giving errors on the following code. ```cpp struct B

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2023-12-19 Thread Younan Zhang via cfe-commits
zyn0217 wrote: > ...which is called during code completion to generate the override function > declarator based on the FunctionDecl of the virtual function in the base. The place you're patching is not only specific to "completing override functions", but handles all completion strings

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2023-12-19 Thread Sirui Mu via cfe-commits
Lancern wrote: > For the test, it would be better to write it in [this > format](https://github.com/llvm/llvm-project/tree/main/clang/test/CodeCompletion) > rather than using clangd. Thanks for your helpful review. I'll move the test to

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2023-12-19 Thread Sirui Mu via cfe-commits
Lancern wrote: > I didn't see anything reflecting this condition; are you still working on > this patch? No, this is not a WIP. I primarily changed the `CodeCompletionResult::createCodeCompletionStringForDecl` function, which is called during code completion to generate the override function

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2023-12-19 Thread Nathan Ridge via cfe-commits
HighCommander4 wrote: Thanks for the patch. For the test, it would be better to write it in [this format](https://github.com/llvm/llvm-project/tree/main/clang/test/CodeCompletion) rather than using clangd. https://github.com/llvm/llvm-project/pull/75937

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2023-12-19 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Sirui Mu (Lancern) Changes If a virtual function is declared with `noexcept`, functions that override this function in the derived classes must be declared with `noexcept` as well. This PR updates code completion in clang Sema. It adds

[clang] [clang-tools-extra] [Sema][clangd] add noexcept to override functions during code completion (PR #75937)

2023-12-19 Thread Sirui Mu via cfe-commits
https://github.com/Lancern created https://github.com/llvm/llvm-project/pull/75937 If a virtual function is declared with `noexcept`, functions that override this function in the derived classes must be declared with `noexcept` as well. This PR updates code completion in clang Sema. It adds