Fix PermissibleIdentifier.allParentsWithSelf

This commit is contained in:
Him188 2020-09-12 16:26:12 +08:00
parent 8fc4da127b
commit c7cde8e790

View File

@ -32,7 +32,7 @@ public interface PermissibleIdentifier {
private fun PermissibleIdentifier.allParentsWithSelf(): Sequence<PermissibleIdentifier> { private fun PermissibleIdentifier.allParentsWithSelf(): Sequence<PermissibleIdentifier> {
return sequence { return sequence {
yield(this@allParentsWithSelf) yield(this@allParentsWithSelf)
yieldAll(parents.asSequence()) yieldAll(parents.asSequence().flatMap { it.allParentsWithSelf() })
} }
} }
} }