Skip to content

Commit 5832ff9

Browse files
committed
Use the newest Kotlin
1 parent 468659b commit 5832ff9

File tree

67 files changed

+167
-2239
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

67 files changed

+167
-2239
lines changed

build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
plugins {
2-
id("kotlinx.team.infra") version "0.4.0-dev-81"
2+
id("kotlinx.team.infra") version "0.4.0-dev-82"
33
kotlin("multiplatform") apply false
44
id("org.jetbrains.kotlinx.kover") version "0.8.0-Beta2"
55
}

core/api/kotlinx-datetime.api

Lines changed: 47 additions & 47 deletions
Large diffs are not rendered by default.

core/api/kotlinx-datetime.klib.api

Lines changed: 41 additions & 41 deletions
Large diffs are not rendered by default.

core/build.gradle.kts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,6 @@ kotlin {
188188
commonMain {
189189
dependencies {
190190
compileOnly("org.jetbrains.kotlinx:kotlinx-serialization-core:$serializationVersion")
191-
api(project(":fake-kotlinx-time"))
192191
}
193192
}
194193

@@ -223,6 +222,10 @@ kotlin {
223222
}
224223
}
225224
}
225+
226+
compilerOptions {
227+
optIn.add("kotlin.time.ExperimentalTime")
228+
}
226229
}
227230

228231
tasks {

core/common/src/Clock.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88
package kotlinx.datetime
99

1010
import kotlin.time.*
11-
import kotlinx.time.Clock
12-
import kotlinx.time.Instant
13-
import kotlinx.time.isDistantFuture
11+
import kotlin.time.Clock
12+
import kotlin.time.Instant
13+
import kotlin.time.isDistantFuture
1414
import kotlin.jvm.JvmMultifileClass
1515
import kotlin.jvm.JvmName
1616
import kotlin.time.Duration.Companion.seconds

core/common/src/DeprecatedClock.kt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ import kotlin.time.TimeSource
2828
*/
2929
@Deprecated(
3030
"Use kotlin.time.Clock instead",
31-
ReplaceWith("kotlinx.time.Clock", "kotlinx.time.Clock"),
31+
ReplaceWith("kotlin.time.Clock", "kotlin.time.Clock"),
3232
level = DeprecationLevel.ERROR
3333
)
3434
public interface Clock {
@@ -65,7 +65,7 @@ public interface Clock {
6565
* @sample kotlinx.datetime.test.samples.ClockSamples.dependencyInjection
6666
*/
6767
public object System : Clock {
68-
override fun now(): Instant = kotlinx.time.Clock.System.now().toDeprecatedInstant()
68+
override fun now(): Instant = kotlin.time.Clock.System.now().toDeprecatedInstant()
6969
}
7070

7171
/** A companion object used purely for namespacing. */

core/common/src/DeprecatedInstant.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,15 @@ import kotlin.time.Duration
2323
import kotlin.time.Duration.Companion.days
2424
import kotlin.time.TimeSource
2525

26-
public fun Instant.toNewInstant(): kotlinx.time.Instant =
27-
kotlinx.time.Instant.fromEpochSeconds(epochSeconds, nanosecondsOfSecond)
26+
public fun Instant.toNewInstant(): kotlin.time.Instant =
27+
kotlin.time.Instant.fromEpochSeconds(epochSeconds, nanosecondsOfSecond)
2828

29-
public fun kotlinx.time.Instant.toDeprecatedInstant(): Instant =
29+
public fun kotlin.time.Instant.toDeprecatedInstant(): Instant =
3030
Instant.fromEpochSeconds(epochSeconds, nanosecondsOfSecond)
3131

3232
@Deprecated(
3333
"Use kotlin.time.Instant instead",
34-
ReplaceWith("kotlinx.time.Instant", "kotlinx.time.Instant"),
34+
ReplaceWith("kotlin.time.Instant", "kotlin.time.Instant"),
3535
level = DeprecationLevel.ERROR
3636
)
3737
@Serializable(with = InstantIso8601Serializer::class)

core/common/src/Instant.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ package kotlinx.datetime
1010
import kotlinx.datetime.format.*
1111
import kotlinx.datetime.internal.*
1212
import kotlin.time.*
13-
import kotlinx.time.Instant
13+
import kotlin.time.Instant
1414
import kotlin.jvm.JvmMultifileClass
1515
import kotlin.jvm.JvmName
1616

core/common/src/TimeZone.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ package kotlinx.datetime
1010

1111
import kotlinx.datetime.serializers.*
1212
import kotlinx.serialization.Serializable
13-
import kotlinx.time.Instant
13+
import kotlin.time.Instant
1414

1515
/**
1616
* A time zone, provides the conversion between [Instant] and [LocalDateTime] values

core/common/src/format/DateTimeComponents.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import kotlinx.datetime.internal.format.*
1212
import kotlinx.datetime.internal.format.parser.Copyable
1313
import kotlinx.datetime.internal.safeMultiply
1414
import kotlin.reflect.*
15-
import kotlinx.time.Instant
15+
import kotlin.time.Instant
1616

1717
/**
1818
* A collection of datetime fields used specifically for parsing and formatting.

0 commit comments

Comments
 (0)