Skip to content

Commit

Permalink
WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
JosephTLyons committed Dec 7, 2024
1 parent fbea750 commit 26abf1a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lenient_parse/internal/build.gleam
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ pub fn float_value(
)

case decimal |> pilkku.to_float {
// `pilkku.to_float` returns 0.0 for both 0.0 and -0.0
Ok(float_value) if float_value == 0.0 && !is_positive -> Ok(-0.0)
Ok(float_value) -> Ok(float_value)
Error(_) -> {
Expand Down Expand Up @@ -153,4 +154,3 @@ fn integer_string(
False -> "-" <> integer_string
}
}
// TODO: Unify the code between build_int and build_float

0 comments on commit 26abf1a

Please sign in to comment.