ultimate-research / ssbh_lib

Reading and writing SSBH file formats in Rust
MIT License
8 stars 3 forks source link

improve error types #88

Closed ScanMountGoat closed 3 years ago

ScanMountGoat commented 3 years ago

Error types can be cleaned up with thiserror. Use the following code snippet instead of simply asserting for panics.

assert!(matches!(
    result,
    Err(BoneTransformError::CycleDetected { index: 0 })
));