@@ -11,7 +11,7 @@ import kotlinx.datetime.serializers.*
11
11
import kotlinx.serialization.Serializable
12
12
13
13
/* *
14
- * The year-month part of [LocalDate], without the day-of-month.
14
+ * The year-month part of [LocalDate], without a day-of-month.
15
15
*
16
16
* This class represents years and months without a reference to a particular time zone.
17
17
* As such, these objects may denote different time intervals in different time zones: for someone in Berlin,
@@ -50,6 +50,7 @@ import kotlinx.serialization.Serializable
50
50
* See sample 3.
51
51
*
52
52
* Additionally, there are several `kotlinx-serialization` serializers for [YearMonth]:
53
+ * - The default serializer, delegating to [toString] and [parse].
53
54
* - [YearMonthIso8601Serializer] for the ISO 8601 extended format.
54
55
* - [YearMonthComponentSerializer] for an object with components.
55
56
*
@@ -65,7 +66,7 @@ public expect class YearMonth
65
66
* The [month] component is 1-based.
66
67
*
67
68
* The supported ranges of components:
68
- * - [year] the range is platform-dependent , but at least is enough to represent year-months of all instants between
69
+ * - [year] the range is unspecified , but at least is enough to represent year-months of all instants between
69
70
* [Instant.DISTANT_PAST] and [Instant.DISTANT_FUTURE] in any time zone.
70
71
* - [month] `1..12`
71
72
*
@@ -120,7 +121,7 @@ public constructor(year: Int, month: Int) : Comparable<YearMonth> {
120
121
/* *
121
122
* Constructs a [YearMonth] instance from the given year-month components.
122
123
*
123
- * The range for [year] is platform-dependent , but at least is enough to represent year-months of all instants
124
+ * The range for [year] is unspecified , but at least is enough to represent year-months of all instants
124
125
* between [Instant.DISTANT_PAST] and [Instant.DISTANT_FUTURE] in any time zone.
125
126
*
126
127
* @throws IllegalArgumentException if [year] is out of range.
@@ -380,7 +381,6 @@ internal fun YearMonth.Companion.fromProlepticMonth(prolepticMonth: Long): YearM
380
381
" Year $year is out of range: ${LocalDate .MIN .year} ..${LocalDate .MAX .year} "
381
382
}
382
383
val month = prolepticMonth.mod(12 ) + 1
383
- println (" proleptic month: ${prolepticMonth} , year: $year , month: $month " )
384
384
return YearMonth (year.toInt(), month)
385
385
}
386
386
0 commit comments