syscalls
syscalls copied to clipboard
Don't panic on From i32
Previous discussed in #41 but closed w/o result.
https://doc.rust-lang.org/std/convert/trait.From.html says:
Note: This trait must not fail. The From trait is intended for perfect conversions. If the conversion can fail or is not perfect, use TryFrom.
[…] the general expectation is that the conversions should typically be restricted as follows:
- The conversion is infallible: if the conversion can fail, use TryFrom instead; don’t provide a From impl that panics.