getAndSet
Deprecated (with error)
Use exchangeAt(index: Int, newValue: Long) instead.
Replace with
this.exchangeAt(index, newValue)
Content copied to clipboard
Atomically sets the value of the element at the given index to the new value and returns the old value of the element.
Provides sequential consistent ordering guarantees.
Since Kotlin
2.1Throws
if the index is out of bounds of this array.