Commit 50ef6a62 authored by Feng Xiao's avatar Feng Xiao

Avoid two consecutive underscores in macro name.

Fixes https://github.com/google/protobuf/issues/3268
parent 0a7120ac
...@@ -1145,8 +1145,8 @@ void FileGenerator::GenerateTopHeaderGuard(io::Printer* printer, ...@@ -1145,8 +1145,8 @@ void FileGenerator::GenerateTopHeaderGuard(io::Printer* printer,
"// Generated by the protocol buffer compiler. DO NOT EDIT!\n" "// Generated by the protocol buffer compiler. DO NOT EDIT!\n"
"// source: $filename$\n" "// source: $filename$\n"
"\n" "\n"
"#ifndef PROTOBUF_$filename_identifier$__INCLUDED\n" "#ifndef PROTOBUF_$filename_identifier$_INCLUDED\n"
"#define PROTOBUF_$filename_identifier$__INCLUDED\n" "#define PROTOBUF_$filename_identifier$_INCLUDED\n"
"\n" "\n"
"#include <string>\n", "#include <string>\n",
"filename", file_->name(), "filename_identifier", filename_identifier); "filename", file_->name(), "filename_identifier", filename_identifier);
...@@ -1156,7 +1156,7 @@ void FileGenerator::GenerateTopHeaderGuard(io::Printer* printer, ...@@ -1156,7 +1156,7 @@ void FileGenerator::GenerateTopHeaderGuard(io::Printer* printer,
void FileGenerator::GenerateBottomHeaderGuard( void FileGenerator::GenerateBottomHeaderGuard(
io::Printer* printer, const string& filename_identifier) { io::Printer* printer, const string& filename_identifier) {
printer->Print( printer->Print(
"#endif // PROTOBUF_$filename_identifier$__INCLUDED\n", "#endif // PROTOBUF_$filename_identifier$_INCLUDED\n",
"filename_identifier", filename_identifier); "filename_identifier", filename_identifier);
} }
......
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