Skip to content

Commit

Permalink
fix(build): Fix service and rpc name conflict
Browse files Browse the repository at this point in the history
Closes #89
  • Loading branch information
LucioFranco committed Oct 23, 2019
1 parent 81c1bb3 commit 0483cef
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tonic-build/src/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ fn generate_unary(
proto_path: &str,
server_trait: Ident,
) -> TokenStream {
let service_ident = Ident::new(&method.proto_name, Span::call_site());
let service_ident = quote::format_ident!("{}Svc", method.proto_name);

let (request, response) = crate::replace_wellknown(proto_path, &method);

Expand Down Expand Up @@ -262,7 +262,7 @@ fn generate_server_streaming(
proto_path: &str,
server_trait: Ident,
) -> TokenStream {
let service_ident = Ident::new(&method.proto_name, Span::call_site());
let service_ident = quote::format_ident!("{}Svc", method.proto_name);

let (request, response) = crate::replace_wellknown(proto_path, &method);

Expand Down Expand Up @@ -305,7 +305,7 @@ fn generate_client_streaming(
proto_path: &str,
server_trait: Ident,
) -> TokenStream {
let service_ident = Ident::new(&method.proto_name, Span::call_site());
let service_ident = quote::format_ident!("{}Svc", method.proto_name);

let (request, response) = crate::replace_wellknown(proto_path, &method);

Expand Down Expand Up @@ -346,7 +346,7 @@ fn generate_streaming(
proto_path: &str,
server_trait: Ident,
) -> TokenStream {
let service_ident = Ident::new(&method.proto_name, Span::call_site());
let service_ident = quote::format_ident!("{}Svc", method.proto_name);

let (request, response) = crate::replace_wellknown(proto_path, &method);

Expand Down

0 comments on commit 0483cef

Please sign in to comment.