Commit 9d6151f
committed
feat(codec): add TypeError::InvalidValue variant
Add InvalidValue { value: i32 } to TypeError for cases where bytes were
read successfully but the decoded value is not a recognized enum variant.
This replaces the misleading use of UnexpectedEof for invalid enum IDs.1 parent 3fb8b48 commit 9d6151f
2 files changed
Lines changed: 16 additions & 0 deletions
Lines changed: 5 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
68 | 75 | | |
69 | 76 | | |
70 | 77 | | |
| |||
397 | 404 | | |
398 | 405 | | |
399 | 406 | | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
400 | 411 | | |
401 | 412 | | |
402 | 413 | | |
| |||
0 commit comments