1
0
Fork 0
mirror of https://gitlab.com/msrd0/gotham-restful.git synced 2025-02-23 04:52:28 +00:00

Merge branch 'master' into openapi

This commit is contained in:
Dominic 2019-10-01 00:55:03 +02:00
commit 887d874063
Signed by: msrd0
GPG key ID: DCC8C247452E98F9

View file

@ -10,7 +10,7 @@ pub mod openapi
macro_rules! rest_struct { macro_rules! rest_struct {
($struct_name:ident { $($field_id:ident : $field_ty:ty),* }) => { ($struct_name:ident { $($field_id:ident : $field_ty:ty),* }) => {
#[derive(serde::Deserialize, serde::Serialize)] #[derive(serde::Deserialize, serde::Serialize)]
struct $struct_name pub struct $struct_name
{ {
$($field_id : $field_ty),* $($field_id : $field_ty),*
} }
@ -66,7 +66,7 @@ macro_rules! rest_struct {
#[macro_export] #[macro_export]
macro_rules! rest_resource { macro_rules! rest_resource {
($res_name:ident, $route:ident => $setup:block) => { ($res_name:ident, $route:ident => $setup:block) => {
struct $res_name; pub struct $res_name;
impl ::gotham_restful::Resource for $res_name impl ::gotham_restful::Resource for $res_name
{ {