aboutsummaryrefslogtreecommitdiff
path: root/src/api/router_macros.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/api/router_macros.rs')
-rw-r--r--src/api/router_macros.rs7
1 files changed, 1 insertions, 6 deletions
diff --git a/src/api/router_macros.rs b/src/api/router_macros.rs
index 07b5570c..cfecbc92 100644
--- a/src/api/router_macros.rs
+++ b/src/api/router_macros.rs
@@ -26,6 +26,7 @@ macro_rules! router_match {
$($meth:ident $path:pat $(if $required:ident)? => $api:ident $(($($conv:ident :: $param:ident),*))?,)*
]) => {{
{
+ #[allow(unused_parens)]
match ($method, $reqpath) {
$(
(&Method::$meth, $path) if true $(&& $query.$required.is_some())? => Endpoint::$api {
@@ -128,12 +129,6 @@ macro_rules! router_match {
}
}
};
- (@if ($($cond:tt)+) then ($($then:tt)*) else ($($else:tt)*)) => {
- $($then)*
- };
- (@if () then ($($then:tt)*) else ($($else:tt)*)) => {
- $($else)*
- };
}
/// This macro is used to generate part of the code in this module. It must be called only one, and