[K/N] Mark WeakReference with ExperimentalNativeApi
As a part of efforts to stabilize Native stdlib #KT-55765.
This commit is contained in:
committed by
Space Team
parent
6f5504e59b
commit
16078ae8e8
@@ -2,7 +2,7 @@
|
||||
* Copyright 2010-2020 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license
|
||||
* that can be found in the LICENSE file.
|
||||
*/
|
||||
@file:OptIn(ExperimentalStdlibApi::class, FreezingIsDeprecated::class)
|
||||
@file:OptIn(ExperimentalStdlibApi::class, FreezingIsDeprecated::class, kotlin.experimental.ExperimentalNativeApi::class)
|
||||
|
||||
package runtime.basic.cleaner_workers
|
||||
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
* that can be found in the LICENSE file.
|
||||
*/
|
||||
|
||||
@file:OptIn(kotlin.experimental.ExperimentalNativeApi::class)
|
||||
|
||||
package runtime.memory.cycles1
|
||||
|
||||
import kotlin.test.*
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
* that can be found in the LICENSE file.
|
||||
*/
|
||||
|
||||
@file:OptIn(kotlin.experimental.ExperimentalNativeApi::class)
|
||||
|
||||
package runtime.memory.weak0
|
||||
|
||||
import kotlin.test.*
|
||||
|
||||
@@ -3,6 +3,8 @@
|
||||
* that can be found in the LICENSE file.
|
||||
*/
|
||||
|
||||
@file:OptIn(kotlin.experimental.ExperimentalNativeApi::class)
|
||||
|
||||
package runtime.memory.weak1
|
||||
|
||||
import kotlin.test.*
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
@file:OptIn(FreezingIsDeprecated::class)
|
||||
@file:OptIn(FreezingIsDeprecated::class, kotlin.experimental.ExperimentalNativeApi::class)
|
||||
package runtime.workers.worker10
|
||||
|
||||
import kotlin.test.*
|
||||
|
||||
@@ -5,11 +5,14 @@
|
||||
|
||||
package kotlin.native.ref
|
||||
|
||||
import kotlin.experimental.ExperimentalNativeApi
|
||||
|
||||
/**
|
||||
* Class WeakReference encapsulates weak reference to an object, which could be used to either
|
||||
* retrieve a strong reference to an object, or return null, if object was already destroyed by
|
||||
* the memory manager.
|
||||
*/
|
||||
@ExperimentalNativeApi
|
||||
public class WeakReference<T : Any> {
|
||||
/**
|
||||
* Creates a weak reference object pointing to an object. Weak reference doesn't prevent
|
||||
|
||||
Reference in New Issue
Block a user