Skip to content

Commit

Permalink
Document floretta::Error
Browse files Browse the repository at this point in the history
  • Loading branch information
samestep committed Nov 20, 2024
1 parent f73a4a8 commit c5776aa
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions crates/floretta/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,14 @@ use wasmparser::{
Payload, Validator, ValidatorResources, WasmFeatures,
};

/// An error that occurred during code transformation.
#[derive(Debug, thiserror::Error)]
pub enum Error {
/// The error occurred while parsing or validating the input Wasm.
#[error("Wasm parsing or validation error: {0}")]
Parse(#[from] BinaryReaderError),

/// The error occurred while reencoding part of the input Wasm into the output Wasm.
#[error("Wasm reencoding error: {0}")]
Reencode(#[from] reencode::Error),
}
Expand Down

0 comments on commit c5776aa

Please sign in to comment.