Removed date/time from generated code, causing commit polution.

Change-Id: I79724416110a3d2241d7eeecf0e12aa6d5b760a0
parent 4bddc6cc
......@@ -55,8 +55,7 @@ void GenerateImports(grpc_generator::File* file,
vars["filename"] = file->filename();
printer->Print(
vars,
"//Generated by flatc compiler (version $flatc_version$) on " __DATE__
" " __TIME__ " \n");
"//Generated by flatc compiler (version $flatc_version$)\n");
printer->Print("//If you make any local changes, they will be lost\n");
printer->Print(vars, "//source: $filename$.fbs\n\n");
printer->Print(vars, "package $Package$;\n\n");
......@@ -337,12 +336,12 @@ static void PrintMethodFields(Printer* p, VARS& vars,
const ServiceDescriptor* service) {
p->Print("// Static method descriptors that strictly reflect the proto.\n");
vars["service_name"] = service->name();
//set of names of rpc input- and output- types that were already encountered.
//this is needed to avoid duplicating type extractor since it's possible that
//the same type is used as an input or output type of more than a single RPC method
std::set<std::string> encounteredTypes;
for (int i = 0; i < service->method_count(); ++i) {
auto method = service->method(i);
vars["arg_in_id"] = to_string((long)2 * i); //trying to make msvc 10 happy
......@@ -382,7 +381,7 @@ static void PrintMethodFields(Printer* p, VARS& vars,
"private static volatile $MethodDescriptor$<$input_type$,\n"
" $output_type$> $method_new_field_name$;\n"
"\n");
if (encounteredTypes.insert(vars["input_type_name"]).second) {
vars["extr_type"] = vars["input_type"];
vars["extr_type_name"] = vars["input_type_name"];
......@@ -394,7 +393,7 @@ static void PrintMethodFields(Printer* p, VARS& vars,
vars["extr_type_name"] = vars["output_type_name"];
PrintTypeExtractor(p, vars);
}
p->Print(
vars,
"@$ExperimentalApi$(\"https://github.com/grpc/grpc-java/issues/"
......
//Generated by flatc compiler (version 1.8.0) on Dec 28 2017 10:07:47
//Generated by flatc compiler (version 1.8.0)
//If you make any local changes, they will be lost
//source: monster_test.fbs
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment