Skip to content

Commit a7e0358

Browse files
committed
[Sema] Print pattern name for ConstraintLocators
1 parent eba95ba commit a7e0358

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

lib/Sema/ConstraintLocator.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -598,6 +598,12 @@ void ConstraintLocator::dump(SourceManager *sm, raw_ostream &out) const {
598598
out << '@';
599599
expr->getLoc().print(out, *sm);
600600
}
601+
} else if (auto *pattern = anchor.dyn_cast<Pattern *>()) {
602+
out << Pattern::getKindName(pattern->getKind()) << "Pattern";
603+
if (sm) {
604+
out << '@';
605+
pattern->getLoc().print(out, *sm);
606+
}
601607
}
602608

603609
for (auto elt : getPath()) {

0 commit comments

Comments
 (0)