diff options
| author | Fuwn <[email protected]> | 2023-04-06 08:34:24 +0000 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2023-04-06 08:34:24 +0000 |
| commit | 873cef6fbba01c99733c97378b5f001779604cf4 (patch) | |
| tree | 4dc531b2005740ec5048350ecdae7ba15836e058 /src/response | |
| parent | feat(cargo): bump 0.3.1 -> 0.3.2 (diff) | |
| download | windmark-873cef6fbba01c99733c97378b5f001779604cf4.tar.xz windmark-873cef6fbba01c99733c97378b5f001779604cf4.zip | |
fix(context): custom parameters format for easy lifetimes
Diffstat (limited to 'src/response')
| -rw-r--r-- | src/response/macros.rs | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/response/macros.rs b/src/response/macros.rs index 76bc950..ebd9799 100644 --- a/src/response/macros.rs +++ b/src/response/macros.rs @@ -23,10 +23,10 @@ macro_rules! sync_response { #[macro_export] macro_rules! $name { ($body:expr /* $(,)? */) => { - |_: ::windmark::context::RouteContext<'_>| ::windmark::Response::$name($body) + |_: ::windmark::context::RouteContext| ::windmark::Response::$name($body) }; ($context:ident, $body:expr /* $(,)? */) => { - |$context: ::windmark::context::RouteContext<'_>| ::windmark::Response::$name($body) + |$context: ::windmark::context::RouteContext| ::windmark::Response::$name($body) }; } )* @@ -40,10 +40,10 @@ macro_rules! async_response { #[macro_export] macro_rules! [< $name _async >] { ($body:expr /* $(,)? */) => { - |_: ::windmark::context::RouteContext<'_>| async { ::windmark::Response::$name($body) } + |_: ::windmark::context::RouteContext| async { ::windmark::Response::$name($body) } }; ($context:ident, $body:expr /* $(,)? */) => { - |$context: ::windmark::context::RouteContext<'_>| async { ::windmark::Response::$name($body) } + |$context: ::windmark::context::RouteContext| async { ::windmark::Response::$name($body) } }; } })* @@ -86,7 +86,7 @@ response!(binary_success_auto); #[macro_export] macro_rules! binary_success { ($body:expr, $mime:expr) => { - |_: ::windmark::context::RouteContext<'_>| { + |_: ::windmark::context::RouteContext| { ::windmark::Response::binary_success($body, $mime) } }; @@ -97,7 +97,7 @@ macro_rules! binary_success { feature to be enabled" ); - |_: ::windmark::context::RouteContext<'_>| { + |_: ::windmark::context::RouteContext| { #[cfg(feature = "auto-deduce-mime")] return ::windmark::Response::binary_success_auto($body); @@ -107,7 +107,7 @@ macro_rules! binary_success { } }}; ($context:ident, $body:expr, $mime:expr) => { - |$context: ::windmark::context::RouteContext<'_>| { + |$context: ::windmark::context::RouteContext| { ::windmark::Response::binary_success($body, $mime) } }; @@ -118,7 +118,7 @@ macro_rules! binary_success { feature to be enabled" ); - |$context: ::windmark::context::RouteContext<'_>| { + |$context: ::windmark::context::RouteContext| { #[cfg(feature = "auto-deduce-mime")] return ::windmark::Response::binary_success_auto($body); |