Skip to content

Commit 67ff1f2

Browse files
committed
Use SAM type whenever possible
1 parent 482c65b commit 67ff1f2

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

compiler/src/dotty/tools/dotc/sbt/ExtractDependencies.scala

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -173,10 +173,7 @@ private final class UsedNamesInClass {
173173
names.foreach { case (name, scopes) =>
174174
builder.append(name.mangledString)
175175
builder.append(" in [")
176-
scopes.forEach(new java.util.function.Consumer[UseScope]() { // TODO: Adapt to SAM type when #2732 is fixed
177-
override def accept(scope: UseScope): Unit =
178-
builder.append(scope.toString)
179-
})
176+
scopes.forEach(scope => builder.append(scope.toString))
180177
builder.append("]")
181178
builder.append(", ")
182179
}

0 commit comments

Comments
 (0)