Skip to content

Commit

Permalink
feat: add support for 128 bit HashMap key serialization
Browse files Browse the repository at this point in the history
  • Loading branch information
Mrreadiness committed Sep 4, 2024
1 parent 27a4ca9 commit 5416cee
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/value/ser.rs
Original file line number Diff line number Diff line change
Expand Up @@ -505,6 +505,10 @@ impl serde::Serializer for MapKeySerializer {
Ok(value.to_string())
}

fn serialize_i128(self, value: i128) -> Result<String> {
Ok(value.to_string())
}

fn serialize_u8(self, value: u8) -> Result<String> {
Ok(value.to_string())
}
Expand All @@ -521,6 +525,10 @@ impl serde::Serializer for MapKeySerializer {
Ok(value.to_string())
}

fn serialize_u128(self, value: u128) -> Result<String> {
Ok(value.to_string())
}

fn serialize_f32(self, value: f32) -> Result<String> {
if value.is_finite() {
Ok(ryu::Buffer::new().format_finite(value).to_owned())
Expand Down

0 comments on commit 5416cee

Please sign in to comment.