base: backport parse_number_{u64,f64} fixes

This backports commits 9d41525a2f and
c99f5af9fe from the main branch (working
on an unstable v0.4) to the v0.3 branch.
This commit is contained in:
Nigel Tao committed 2026-10-20 14:17:58 +11:00
1 parent d1a6f2c3de
commit 32a23a9bb5
3 files changed
+40 -42

No files matched your search

+2
View File
@@ -219,6 +219,7 @@ wuffs_base__parse_number_u64(wuffs_base__slice_u8 s, uint32_t options) {
if (p < q) {
goto hexadecimal;
}
goto fail_bad_argument;
} else if ((*p == 'd') || (*p == 'D')) {
p++;
@@ -229,6 +230,7 @@ wuffs_base__parse_number_u64(wuffs_base__slice_u8 s, uint32_t options) {
if (p < q) {
goto decimal;
}
goto fail_bad_argument;
}
if (options & WUFFS_BASE__PARSE_NUMBER_XXX__ALLOW_MULTIPLE_LEADING_ZEROES) {