Skip to content

Fix integral decoding from property maps - #3232

Open
arpitagarwal1301 wants to merge 1 commit into
Kotlin:devfrom
arpitagarwal1301:fix/1208-decodefrommap-inserts-double-into
Open

Fix integral decoding from property maps#3232
arpitagarwal1301 wants to merge 1 commit into
Kotlin:devfrom
arpitagarwal1301:fix/1208-decodefrommap-inserts-double-into

Conversation

@arpitagarwal1301

Copy link
Copy Markdown

Closes #1208

Summary

  • validate Byte, Short, and Int values from Any-backed property maps before converting them
  • accept only finite, integral, safe JavaScript numbers when decoding a Long
  • preserve exact runtime-type behavior on JVM and Native and add focused common, JS, and JVM regression tests

Validation

  • ./gradlew :kotlinx-serialization-properties:jvmTest :kotlinx-serialization-properties:jsNodeTest --tests '*Properties*NumericTest*'
  • ./gradlew :kotlinx-serialization-properties:jvmTest :kotlinx-serialization-properties:jsNodeTest
  • ./gradlew :kotlinx-serialization-properties:check (passed through JVM, JS, macOS ARM64 Native, ABI/artifact, and cross-target checks; stopped only because the local Xcode installation lacks the tvOS Simulator ARM64 SDK)
  • git diff --check

@arpitagarwal1301
arpitagarwal1301 changed the base branch from master to dev July 23, 2026 15:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

decodeFromMap() inserts Double into Int variable

1 participant