[atomicfu-JVM] Preparation for commonization of JVM and K/N transformers
The following updates in the JVM/IR plugin were made: * Lots of refactoring with preparation for K/N support: commonization of transformations. * Improved error handling (checks for visibility constraints, appending message about usage constraints in case of an error). * Explicit requirements for the visibility of atomic properties: to prevent leaking they should be private/internal or be members of private/internal classes. * Fixed visibility of generated properties: volatile properties are always private and atomic updaters have the same visibility as the original atomic property. * Volatile fields are generated from scratch and original atomic properties are removed. * Delegated properties support is fixed (only declaration in the same scope is allowed). * Non-inline atomic extensions are forbidden. * For top-level atomics: only one wrapper class per file (with corresponding visibility) is generated. * Bug fixes. The corresponding tickets: https://github.com/Kotlin/kotlinx-atomicfu/issues/322 KT-60528 Merge-request: KT-MR-10579 Merged-by: Maria Sokolova <maria.sokolova@jetbrains.com>
This commit is contained in:
+39
@@ -0,0 +1,39 @@
|
||||
@kotlin.Metadata
|
||||
public final class SimpleLock {
|
||||
// source: 'SimpleLockTest.kt'
|
||||
private synthetic final static field _locked$volatile$FU: java.util.concurrent.atomic.AtomicIntegerFieldUpdater
|
||||
private synthetic volatile field _locked$volatile: int
|
||||
static method <clinit>(): void
|
||||
public method <init>(): void
|
||||
private synthetic final static method get_locked$volatile$FU(): java.util.concurrent.atomic.AtomicIntegerFieldUpdater
|
||||
private synthetic final method get_locked$volatile(): int
|
||||
private synthetic final method loop$atomicfu(p0: java.util.concurrent.atomic.AtomicIntegerFieldUpdater, p1: kotlin.jvm.functions.Function1, p2: java.lang.Object): void
|
||||
private synthetic final method set_locked$volatile(p0: int): void
|
||||
public final method withLock(@org.jetbrains.annotations.NotNull p0: kotlin.jvm.functions.Function0): java.lang.Object
|
||||
}
|
||||
|
||||
@kotlin.Metadata
|
||||
final class SimpleLockTest$withLock$result$1 {
|
||||
// source: 'SimpleLockTest.kt'
|
||||
enclosing method SimpleLockTest.withLock()V
|
||||
public final static field INSTANCE: SimpleLockTest$withLock$result$1
|
||||
inner (anonymous) class SimpleLockTest$withLock$result$1
|
||||
static method <clinit>(): void
|
||||
method <init>(): void
|
||||
public synthetic bridge method invoke(): java.lang.Object
|
||||
public final @org.jetbrains.annotations.NotNull method invoke(): java.lang.String
|
||||
}
|
||||
|
||||
@kotlin.Metadata
|
||||
public final class SimpleLockTest {
|
||||
// source: 'SimpleLockTest.kt'
|
||||
inner (anonymous) class SimpleLockTest$withLock$result$1
|
||||
public method <init>(): void
|
||||
public final method withLock(): void
|
||||
}
|
||||
|
||||
@kotlin.Metadata
|
||||
public final class SimpleLockTestKt {
|
||||
// source: 'SimpleLockTest.kt'
|
||||
public final static @org.jetbrains.annotations.NotNull method box(): java.lang.String
|
||||
}
|
||||
Reference in New Issue
Block a user