diff options
Diffstat (limited to 'src/macros.rs')
| -rw-r--r-- | src/macros.rs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/macros.rs b/src/macros.rs index 831a37c8..a1c182fb 100644 --- a/src/macros.rs +++ b/src/macros.rs @@ -12,6 +12,7 @@ macro_rules! error_type { impl std::fmt::Display for $err { fn fmt(&self, $f: &mut std::fmt::Formatter) -> std::fmt::Result { + #[allow(unused)] let $var = self; $show } @@ -22,6 +23,7 @@ macro_rules! error_type { impl std::error::Error for $err { // The source method is only generated if an implementation was given. $(fn source(&self) -> Option<&(dyn std::error::Error + 'static)> { + #[allow(unused)] let $var = self; $source })* |
