[libcxx-commits] [clang] [libcxx] [Clang] Normalize constraints before checking for satisfaction (PR #141776)
Younan Zhang via libcxx-commits
libcxx-commits at lists.llvm.org
Wed Sep 24 03:06:50 PDT 2025
================
@@ -2481,10 +2485,13 @@ auto SubsumptionChecker::find(const AtomicConstraint *Ori) -> Literal {
ID.AddBoolean(Ori->hasParameterMapping());
if (Ori->hasParameterMapping()) {
const auto &Mapping = Ori->getParameterMapping();
- for (const TemplateArgumentLoc &TAL : Mapping) {
- SemaRef.getASTContext()
- .getCanonicalTemplateArgument(TAL.getArgument())
- .Profile(ID, SemaRef.getASTContext());
+ const NormalizedConstraint::OccurenceList &Indexes =
+ Ori->mappingOccurenceListForSubsumption();
+ for (auto [Idx, TAL] : llvm::enumerate(Mapping)) {
+ if (Indexes[Idx])
----------------
zyn0217 wrote:
Does the index match? The OccurenceList matches against a template parameter (of atomics) while the Mapping at this point doesn't always correspond to that list.
https://github.com/llvm/llvm-project/pull/141776
More information about the libcxx-commits
mailing list