Skip to content

Commit

Permalink
Add comment
Browse files Browse the repository at this point in the history
  • Loading branch information
vmishenev committed Feb 28, 2023
1 parent 80120f2 commit 4b87328
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions core/src/main/kotlin/model/DisplaySourceSet.kt
Expand Up @@ -5,6 +5,14 @@ import org.jetbrains.dokka.DokkaSourceSetID
import org.jetbrains.dokka.Platform
import org.jetbrains.dokka.utilities.SelfRepresentingSingletonSet

/**
* TODO: fix the example (symmetric equivalence relation with [Set]):
* ```
* val ds = DokkaSourceSetImpl(sourceSetID = DokkaSourceSetID("", "")).toDisplaySourceSet()
* println(setOf(ds) == ds) // true
* println(ds == setOf(ds)) // false
* ```
*/
data class DisplaySourceSet(
val sourceSetIDs: CompositeSourceSetID,
val name: String,
Expand Down
Expand Up @@ -96,6 +96,7 @@ open class DokkaLocationProvider(
.mapNotNull { ssid ->
dokkaContext.configuration.sourceSets.find { it.sourceSetID == ssid }?.toDisplaySourceSet()
}.map {
// be careful `data DisplaySourceSet: Set<DisplaySourceSet>` but `setOf(someDisplaySourceSet) != someDisplaySourceSet`
setOf(it)
}
}
Expand Down

0 comments on commit 4b87328

Please sign in to comment.