Skip to content

Commit

Permalink
docs(#137): improve documentation of notEmptySetOf function
Browse files Browse the repository at this point in the history
  • Loading branch information
LVMVRQUXL committed Jul 27, 2023
1 parent c3c6756 commit ae15204
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/commonMain/kotlin/kotools/types/collection/NotEmptySet.kt
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@ import kotlin.jvm.JvmInline
/**
* Creates a [NotEmptySet] starting with a [head] and containing all the
* elements of the optional [tail].
*
* ```kotlin
* import kotools.types.collection.NotEmptySet
* import kotools.types.collection.notEmptySetOf
*
* val integers: NotEmptySet<Int> = notEmptySetOf(1, 2, 3, 1)
* println(integers) // [1, 2, 3]
* ```
*/
@SinceKotoolsTypes("4.0")
public fun <E> notEmptySetOf(head: E, vararg tail: E): NotEmptySet<E> =
Expand Down

0 comments on commit ae15204

Please sign in to comment.