diff options
Diffstat (limited to 'src/google/protobuf/compiler/csharp/csharp_umbrella_class.cc')
-rw-r--r-- | src/google/protobuf/compiler/csharp/csharp_umbrella_class.cc | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/google/protobuf/compiler/csharp/csharp_umbrella_class.cc b/src/google/protobuf/compiler/csharp/csharp_umbrella_class.cc index 399c64e1..7cf101b0 100644 --- a/src/google/protobuf/compiler/csharp/csharp_umbrella_class.cc +++ b/src/google/protobuf/compiler/csharp/csharp_umbrella_class.cc @@ -135,7 +135,9 @@ void UmbrellaClassGenerator::WriteIntroduction(io::Printer* printer) { } printer->Print( - "[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n"); + "/// <summary>Holder for reflection information generated from $file_name$</summary>\n" + "[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\n", + "file_name", file_->name()); WriteGeneratedCodeAttributes(printer); printer->Print( "$access_level$ static partial class $umbrella_class_name$ {\n" @@ -148,12 +150,14 @@ void UmbrellaClassGenerator::WriteIntroduction(io::Printer* printer) { void UmbrellaClassGenerator::WriteDescriptor(io::Printer* printer) { printer->Print( "#region Descriptor\n" + "/// <summary>File descriptor for $file_name$</summary>\n" "public static pbr::FileDescriptor Descriptor {\n" " get { return descriptor; }\n" "}\n" "private static pbr::FileDescriptor descriptor;\n" "\n" "static $umbrella_class_name$() {\n", + "file_name", file_->name(), "umbrella_class_name", umbrellaClassname_); printer->Indent(); printer->Print( @@ -166,7 +170,7 @@ void UmbrellaClassGenerator::WriteDescriptor(io::Printer* printer) { // TODO(jonskeet): Consider a C#-escaping format here instead of just Base64. std::string base64 = FileDescriptorToBase64(file_); while (base64.size() > 60) { - printer->Print("\"$base64$\", \n", "base64", base64.substr(0, 60)); + printer->Print("\"$base64$\",\n", "base64", base64.substr(0, 60)); base64 = base64.substr(60); } printer->Print("\"$base64$\"));\n", "base64", base64); |