kotlin-stdlib / kotlin.native.concurrent / AtomicNativePtr / compareAndSet compareAndSet Native 1.3 fun compareAndSet( expected: NativePtr, new: NativePtr): Boolean Compares value with expected and replaces it with new value if values matches. Parameters expected - the expected value new - the new value Return true if successful