Parse/validate ISBNs in Zig

Add error-path test coverage and reject X in ISBN-13 input master

Add tests for malformed input, invalid check digits, the '0' check-digit branches of both formats, and the 979 prefix. Writing them surfaced a parser bug: 'X' was accepted as the 10th digit of a 13-digit input, and since 'X' - '0' is 40, which at weight 3 contributes 120 = 0 (mod 10), a string like 978-0-306-40X15-5 passed the checksum and parsed as a valid ISBN-13 (the non-SIMD build would hit a debug assertion instead). parse now rejects any 13-digit input containing 'X'. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016uAPiLrcvxP4hyvSLokRrp


+50
1 changed file