[all-commits] [llvm/llvm-project] 59179d: [Sema] Merge C++20 concept definitions from differ...
Ilya Biryukov via All-commits
all-commits at lists.llvm.org
Mon Jul 25 05:53:12 PDT 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 59179d72b2e3d3b99ebc342374c9c797d526ac5d
https://github.com/llvm/llvm-project/commit/59179d72b2e3d3b99ebc342374c9c797d526ac5d
Author: Ilya Biryukov <ibiryukov at google.com>
Date: 2022-07-25 (Mon, 25 Jul 2022)
Changed paths:
M clang/include/clang/Basic/DiagnosticSemaKinds.td
M clang/include/clang/Sema/Sema.h
M clang/lib/Sema/SemaTemplate.cpp
A clang/test/Modules/merge-concepts-cxx-modules.cpp
A clang/test/Modules/merge-concepts-redefinition-error.cpp
A clang/test/Modules/merge-concepts.cpp
Log Message:
-----------
[Sema] Merge C++20 concept definitions from different modules in same TU
Currently the C++20 concepts are only merged in `ASTReader`, i.e. when
coming from different TU. This can causes ambiguious reference errors when
trying to access the same concept that should otherwise be merged.
Please see the added test for an example.
Note that we currently use `ASTContext::isSameEntity` to check for ODR
violations. However, it will not check that concept requirements match.
The same issue holds for mering concepts from different TUs, I added a
FIXME and filed a GH issue to track this:
https://github.com/llvm/llvm-project/issues/56310
Reviewed By: ChuanqiXu
Differential Revision: https://reviews.llvm.org/D128921
More information about the All-commits
mailing list