Use fully qualified path for futures_core::Stream in codegen (#591)

This commit is contained in:
Ben Sully
2021-03-28 19:31:20 +02:00
committed by GitHub
parent 2788628916
commit 6c898a239f
7 changed files with 40 additions and 4 deletions
+2 -2
View File
@@ -182,7 +182,7 @@ fn generate_trait_methods<T: Service>(
quote! {
#stream_doc
type #stream: Stream<Item = Result<#res_message, tonic::Status>> + Send + Sync + 'static;
type #stream: futures_core::Stream<Item = Result<#res_message, tonic::Status>> + Send + Sync + 'static;
#method_doc
async fn #name(&self, request: tonic::Request<#req_message>)
@@ -198,7 +198,7 @@ fn generate_trait_methods<T: Service>(
quote! {
#stream_doc
type #stream: Stream<Item = Result<#res_message, tonic::Status>> + Send + Sync + 'static;
type #stream: futures_core::Stream<Item = Result<#res_message, tonic::Status>> + Send + Sync + 'static;
#method_doc
async fn #name(&self, request: tonic::Request<tonic::Streaming<#req_message>>)