diff --git a/src/compiler/cpp_generator.cc b/src/compiler/cpp_generator.cc index 13d65d9d1c6..37178d9093d 100644 --- a/src/compiler/cpp_generator.cc +++ b/src/compiler/cpp_generator.cc @@ -1365,7 +1365,7 @@ void PrintHeaderService(grpc_generator::Printer* printer, } PrintHeaderClientMethodCallbackInterfacesEnd(printer, vars); printer->Outdent(); - printer->Print("private:\n"); + printer->Print(" private:\n"); printer->Indent(); for (int i = 0; i < service->method_count(); ++i) { PrintHeaderClientMethodInterfaces(printer, service->method(i).get(), vars, diff --git a/test/cpp/codegen/compiler_test_golden b/test/cpp/codegen/compiler_test_golden index b509a93353e..56a2cf09427 100644 --- a/test/cpp/codegen/compiler_test_golden +++ b/test/cpp/codegen/compiler_test_golden @@ -129,7 +129,7 @@ class ServiceA final { typedef class async_interface experimental_async_interface; virtual class async_interface* async() { return nullptr; } class async_interface* experimental_async() { return async(); } - private: + private: virtual ::grpc::ClientAsyncResponseReaderInterface< ::grpc::testing::Response>* AsyncMethodA1Raw(::grpc::ClientContext* context, const ::grpc::testing::Request& request, ::grpc::CompletionQueue* cq) = 0; virtual ::grpc::ClientAsyncResponseReaderInterface< ::grpc::testing::Response>* PrepareAsyncMethodA1Raw(::grpc::ClientContext* context, const ::grpc::testing::Request& request, ::grpc::CompletionQueue* cq) = 0; virtual ::grpc::ClientWriterInterface< ::grpc::testing::Request>* MethodA2Raw(::grpc::ClientContext* context, ::grpc::testing::Response* response) = 0; @@ -738,7 +738,7 @@ class ServiceB final { typedef class async_interface experimental_async_interface; virtual class async_interface* async() { return nullptr; } class async_interface* experimental_async() { return async(); } - private: + private: virtual ::grpc::ClientAsyncResponseReaderInterface< ::grpc::testing::Response>* AsyncMethodB1Raw(::grpc::ClientContext* context, const ::grpc::testing::Request& request, ::grpc::CompletionQueue* cq) = 0; virtual ::grpc::ClientAsyncResponseReaderInterface< ::grpc::testing::Response>* PrepareAsyncMethodB1Raw(::grpc::ClientContext* context, const ::grpc::testing::Request& request, ::grpc::CompletionQueue* cq) = 0; };