mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-04 15:45:25 +00:00
Previously, we would use lossy strtod() conversion. This was bad, especially since we switched from internally storing Calculator state in a double to storing it in the KeypadValue class some time ago. This commit adds a constructor for the KeypadValue class that is not lossy by using strtoll(). It handles numbers with and without decimal points as well as negative numbers correctly.