forked from naskya/firefish
10 lines
252 B
Rust
10 lines
252 B
Rust
#[macro_export]
|
|
macro_rules! impl_napi_error_from {
|
|
($a:ty) => {
|
|
impl From<$a> for napi::Error {
|
|
fn from(reason: $a) -> napi::Error {
|
|
napi::Error::from_reason(reason.to_string())
|
|
}
|
|
}
|
|
};
|
|
}
|