From fc0393436f1e9698370099b0e9d03fc53ceb85cf Mon Sep 17 00:00:00 2001 From: Alexander Nozik Date: Mon, 15 Apr 2024 18:01:58 +0300 Subject: [PATCH] Document `ShapeND.asArray()` --- .../src/commonMain/kotlin/space/kscience/kmath/nd/ShapeND.kt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kmath-core/src/commonMain/kotlin/space/kscience/kmath/nd/ShapeND.kt b/kmath-core/src/commonMain/kotlin/space/kscience/kmath/nd/ShapeND.kt index dee22e49f..d5cdc6286 100644 --- a/kmath-core/src/commonMain/kotlin/space/kscience/kmath/nd/ShapeND.kt +++ b/kmath-core/src/commonMain/kotlin/space/kscience/kmath/nd/ShapeND.kt @@ -68,6 +68,9 @@ public operator fun ShapeND.component3(): Int = get(2) */ public fun ShapeND.toArray(): IntArray = array.copyOf() +/** + * Provide internal content of [ShapeND]. Must not be modified. + */ @UnsafeKMathAPI public fun ShapeND.asArray(): IntArray = array