chore: checkpoint before Python removal

This commit is contained in:
2026-03-26 22:33:59 +00:00
parent 683cec9307
commit e568ddf82a
29972 changed files with 11269302 additions and 2 deletions

18
vendor/serde_json/src/lexical/digit.rs vendored Normal file
View File

@@ -0,0 +1,18 @@
// Adapted from https://github.com/Alexhuszagh/rust-lexical.
//! Helpers to convert and add digits from characters.
// Convert u8 to digit.
#[inline]
pub(crate) fn to_digit(c: u8) -> Option<u32> {
(c as char).to_digit(10)
}
// Add digit to mantissa.
#[inline]
pub(crate) fn add_digit(value: u64, digit: u32) -> Option<u64> {
match value.checked_mul(10) {
None => None,
Some(n) => n.checked_add(digit as u64),
}
}