Skip to content

Commit 048a64d

Browse files
committed
RequirementMachine: Tweak debug output and fix typo
1 parent a08bfb9 commit 048a64d

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

lib/AST/RequirementMachine/MinimalConformances.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -470,7 +470,9 @@ void MinimalConformances::collectConformanceRules() {
470470
/// That is, we can choose to eliminate <X>.[P], but not <Y>.[P], or vice
471471
/// versa; but it is never valid to eliminate both.
472472
void MinimalConformances::computeCandidateConformancePaths() {
473-
for (const auto &loop : System.getLoops()) {
473+
for (unsigned loopID : indices(System.getLoops())) {
474+
const auto &loop = System.getLoops()[loopID];
475+
474476
if (loop.isDeleted())
475477
continue;
476478

@@ -483,7 +485,7 @@ void MinimalConformances::computeCandidateConformancePaths() {
483485
continue;
484486

485487
if (Debug.contains(DebugFlags::MinimalConformances)) {
486-
llvm::dbgs() << "Candidate homotopy generator: ";
488+
llvm::dbgs() << "Candidate homotopy generator: (#" << loopID << ") ";
487489
loop.dump(llvm::dbgs(), System);
488490
llvm::dbgs() << "\n";
489491
}

0 commit comments

Comments
 (0)