Skip to content

Commit

Permalink
Merge pull request #869 from k163377/entries
Browse files Browse the repository at this point in the history
Replaced Enum.values with Enum.entries
  • Loading branch information
k163377 authored Dec 15, 2024
2 parents d94e3d9 + 898ee9e commit 0d54fe6
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions release-notes/CREDITS-2.x
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ WrongWrong (@k163377)
# 2.18.0 (26-Sep-2024)

WrongWrong (@k163377)
* #869: Replaced Enum.values with Enum.entries
* #818: Optimize the search process for creators
* #817: Fixed nullability of convertValue function argument
* #782: Organize deprecated contents
Expand Down
1 change: 1 addition & 0 deletions release-notes/VERSION-2.x
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Co-maintainers:

2.19.0 (not yet released)

#869: By using Enum.entries in the acquisition of KotlinFeature.defaults, the initialization load was reduced, albeit slightly.
#861: Kotlin has been upgraded to 1.9.24.
#858: Minor performance improvement of findDefaultCreator in edge cases.
#839: Remove useKotlinPropertyNameForGetter and unify with kotlinPropertyNameAsImplicitName.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ enum class KotlinFeature(internal val enabledByDefault: Boolean) {

companion object {
internal val defaults
get() = values().fold(BitSet(Int.SIZE_BITS)) { acc, cur ->
get() = entries.fold(BitSet(Int.SIZE_BITS)) { acc, cur ->
acc.apply { if (cur.enabledByDefault) this.or(cur.bitSet) }
}
}
Expand Down

0 comments on commit 0d54fe6

Please sign in to comment.