Skip to content

Commit 019a06d

Browse files
committed
Remove a redundant parameter
1 parent 2ca093f commit 019a06d

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

core/build.gradle.kts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,6 @@ val serializationVersion: String by project
2929

3030
java {
3131
toolchain { languageVersion.set(JavaLanguageVersion.of(mainJavaToolchainVersion)) }
32-
with(javaToolchains.launcherFor(toolchain).get().metadata) {
33-
logger.info("Using JDK $languageVersion toolchain installed in $installationPath")
34-
}
3532
}
3633

3734
kotlin {

core/windows/src/internal/TzdbInRegistry.kt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ internal class TzdbInRegistry: TimeZoneDatabase {
6060
}
6161
}
6262
}
63-
if (offsets.isEmpty()) { offsets.add(recurring.offsetAtYearStart(2020)) }
63+
if (offsets.isEmpty()) { offsets.add(recurring.offsetAtYearStart()) }
6464
TimeZoneRules(transitionEpochSeconds, offsets, recurringRules)
6565
}
6666
put(name, rules)
@@ -294,7 +294,7 @@ private fun SYSTEMTIME.toMonthDayTime(): MonthDayTime {
294294

295295
private sealed interface PerYearZoneRulesData {
296296
val transitions: List<RecurringZoneRules.Rule<MonthDayTime>>
297-
fun offsetAtYearStart(year: Int): UtcOffset
297+
fun offsetAtYearStart(): UtcOffset
298298
}
299299

300300
private class PerYearZoneRulesDataWithoutTransitions(
@@ -303,7 +303,7 @@ private class PerYearZoneRulesDataWithoutTransitions(
303303
override val transitions: List<RecurringZoneRules.Rule<MonthDayTime>>
304304
get() = emptyList()
305305

306-
override fun offsetAtYearStart(year: Int): UtcOffset = standardOffset
306+
override fun offsetAtYearStart(): UtcOffset = standardOffset
307307

308308
override fun toString(): String = "standard offset is $standardOffset"
309309
}
@@ -323,7 +323,7 @@ private class PerYearZoneRulesDataWithTransitions(
323323
val standardTransition get() =
324324
RecurringZoneRules.Rule(standardTransitionTime, offsetBefore = daylightOffset, offsetAfter = standardOffset)
325325

326-
override fun offsetAtYearStart(year: Int): UtcOffset = standardOffset
326+
override fun offsetAtYearStart(): UtcOffset = standardOffset // TODO: not true in all years + all zones
327327

328328
override fun toString(): String = "standard offset is $standardOffset" +
329329
", daylight offset is $daylightOffset" +
@@ -348,4 +348,4 @@ private val START_OF_YEAR = MonthDayTime(
348348
date = JulianDayOfYear(0),
349349
time = MonthDayTime.TransitionLocaltime(0),
350350
offset = MonthDayTime.OffsetResolver.WallClockOffset,
351-
)
351+
)

0 commit comments

Comments
 (0)