Enable documentation for optional features on docs.rs

This commit is contained in:
Tim Kuehn
2020-08-02 20:57:21 -07:00
parent 240c436b34
commit f65dd05949
5 changed files with 11 additions and 9 deletions

View File

@@ -523,7 +523,7 @@ impl<'a> ServiceGenerator<'a> {
#vis trait #service_ident: Clone {
#( #types_and_fns )*
/// Returns a serving function to use with tarpc::server::Server.
/// Returns a serving function to use with [tarpc::server::Channel::respond_with].
fn serve(self) -> #server_ident<Self> {
#server_ident { service: self }
}
@@ -537,6 +537,7 @@ impl<'a> ServiceGenerator<'a> {
} = self;
quote! {
/// A serving function to use with [tarpc::server::Channel::respond_with].
#[derive(Clone)]
#vis struct #server_ident<S> {
service: S,