fdt
fdt copied to clipboard
Remove `unwrap`'s/`expect`'s in favor of propagating up errors
I think it would be nice to get rid of some of these panics in favor of propagating up errors
This is actually one of the main purposes of the rewrite of the crate that I started a few months ago, though I'm unsure of when it'll be released, but this is planned!
I've done the work in my fork, if you want to crib some stuff: https://codeberg.org/weathered-steel/flat_device_tree/pulls/12/files
I've made some good headway on the rewrite
branch which uses GATs to implement a "panic mode" parameter which allows for both APIs to exist simultaneously without duplication. not sure on an ETA for a alpha release of the crate but this should help both support users who don't want to panic at all and those who would rather have a more ergonomic API in exchange for potential panics.
not sure on an ETA for a alpha release of the crate but this should help both support users who don't want to panic at all and those who would rather have a more ergonomic API in exchange for potential panics.
Let me know when you have something ready for review.
I'm definitely interested to see what you worked out, since this is relevant to other projects I'm currently working on.
Thanks for the update :heart: