remove unnecessary toInt

This commit is contained in:
Alexander Nozik 2021-11-10 11:51:20 +03:00
parent fa9ff4c978
commit 9a1f8a2266

View File

@ -26,6 +26,7 @@ internal operator fun IntRange.contains(other: IntRange): Boolean = (other.first
public interface Series<T> : Buffer<T> { public interface Series<T> : Buffer<T> {
public val origin: Buffer<T> public val origin: Buffer<T>
/** /**
* Absolute position of start of this [Series] in [SeriesAlgebra] * Absolute position of start of this [Series] in [SeriesAlgebra]
*/ */
@ -114,7 +115,7 @@ public class SeriesAlgebra<T, out A : Ring<T>, out BA : BufferAlgebra<T, A>, L>(
public operator fun Buffer<T>.get(label: L): T? { public operator fun Buffer<T>.get(label: L): T? {
val index = labels.indexOf(label) val index = labels.indexOf(label)
if (index == -1) return null if (index == -1) return null
return getAbsolute(index + offset.toInt()) return getAbsolute(index + offset)
} }
/** /**