Skip to content

Commit 80e4d9c

Browse files
committed
warning fixes
1 parent d16e98a commit 80e4d9c

5 files changed

Lines changed: 6 additions & 3 deletions

File tree

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@ org.gradle.jvmargs=-Xmx2048m
55
kotlin.mpp.androidSourceSetLayoutVersion=2
66
kotlin.mpp.applyDefaultHierarchyTemplate=false
77
# Allow inconsistent JVM targets: Kotlin targets 1.8 (for compatibility), but module-info.java requires 9+.
8-
kotlin.jvm.target.validation.mode=warning
8+
kotlin.jvm.target.validation.mode=ignore
99
kotlin.mpp.enableCInteropCommonization=true

src/darwinMain/kotlin/io/github/oshai/kotlinlogging/internal/KLoggingClock.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ package io.github.oshai.kotlinlogging.internal
22

33
import kotlin.system.getTimeMillis
44

5-
public actual fun getCurrentTime(): Long = getTimeMillis()
5+
@Suppress("DEPRECATION") public actual fun getCurrentTime(): Long = getTimeMillis()

src/jvmMain/kotlin/io/github/oshai/kotlinlogging/KLogging.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,14 @@ package io.github.oshai.kotlinlogging
1212
* ```
1313
*/
1414
@Deprecated("Use KLogger instead", ReplaceWith("KLogger", "io.github.oshai.kotlinlogging.KLogger"))
15+
@Suppress("DEPRECATION")
1516
public open class KLogging : KLoggable {
1617
override val logger: KLogger = logger()
1718
}
1819

1920
/** A class with logging capabilities and explicit logger name */
2021
@Deprecated("Use KLogger instead", ReplaceWith("KLogger", "io.github.oshai.kotlinlogging.KLogger"))
22+
@Suppress("DEPRECATION")
2123
public open class NamedKLogging(name: String) : KLoggable {
2224
override val logger: KLogger = logger(name)
2325
}

src/jvmMain/kotlin/io/github/oshai/kotlinlogging/logback/internal/LogbackLogEvent.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ internal class LogbackLogEvent(
4141
override fun getMessage(): String =
4242
kLoggingEvent.internalCompilerData?.messageTemplate ?: kLoggingEvent.message ?: ""
4343

44+
@Suppress("UNCHECKED_CAST")
4445
override fun getArgumentArray(): Array<Object>? = kLoggingEvent.arguments as? Array<Object>
4546

4647
override fun getFormattedMessage(): String? = kLoggingEvent.message

src/nativeMain/kotlin/io/github/oshai/kotlinlogging/internal/KLoggingClock.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ package io.github.oshai.kotlinlogging.internal
22

33
import kotlin.system.getTimeMillis
44

5-
public actual fun getCurrentTime(): Long = getTimeMillis()
5+
@Suppress("DEPRECATION") public actual fun getCurrentTime(): Long = getTimeMillis()

0 commit comments

Comments
 (0)