aboutsummaryrefslogtreecommitdiff
path: root/src/google/protobuf/compiler/plugin.cc
diff options
context:
space:
mode:
authorJisi Liu <jisi.liu@gmail.com>2015-02-28 14:51:22 -0800
committerJisi Liu <jisi.liu@gmail.com>2015-02-28 17:06:49 -0800
commit885b612f74f133678bf82808c589331e4c59dad9 (patch)
treee5f3f65b41af477c52810053b8694896c8bcd1f7 /src/google/protobuf/compiler/plugin.cc
parent1939efed2db35020b7830a4927f10feac47b6757 (diff)
downloadprotobuf-885b612f74f133678bf82808c589331e4c59dad9.tar.gz
protobuf-885b612f74f133678bf82808c589331e4c59dad9.tar.bz2
protobuf-885b612f74f133678bf82808c589331e4c59dad9.zip
Down integrate from Google internal branch for C++ and Java.
- Maps for C++ lite - C++ Arena optimizations. - Java Lite runtime code size optimization. Change-Id: I7537a4357c1cb385d23f9e8aa7ffdfeefe079f13
Diffstat (limited to 'src/google/protobuf/compiler/plugin.cc')
-rw-r--r--src/google/protobuf/compiler/plugin.cc13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/google/protobuf/compiler/plugin.cc b/src/google/protobuf/compiler/plugin.cc
index 9011a6bd..ad501acf 100644
--- a/src/google/protobuf/compiler/plugin.cc
+++ b/src/google/protobuf/compiler/plugin.cc
@@ -95,7 +95,7 @@ class GeneratorResponseContext : public GeneratorContext {
int PluginMain(int argc, char* argv[], const CodeGenerator* generator) {
if (argc > 1) {
- cerr << argv[0] << ": Unknown option: " << argv[1] << endl;
+ std::cerr << argv[0] << ": Unknown option: " << argv[1] << std::endl;
return 1;
}
@@ -106,7 +106,8 @@ int PluginMain(int argc, char* argv[], const CodeGenerator* generator) {
CodeGeneratorRequest request;
if (!request.ParseFromFileDescriptor(STDIN_FILENO)) {
- cerr << argv[0] << ": protoc sent unparseable request to plugin." << endl;
+ std::cerr << argv[0] << ": protoc sent unparseable request to plugin."
+ << std::endl;
return 1;
}
@@ -123,9 +124,9 @@ int PluginMain(int argc, char* argv[], const CodeGenerator* generator) {
for (int i = 0; i < request.file_to_generate_size(); i++) {
parsed_files.push_back(pool.FindFileByName(request.file_to_generate(i)));
if (parsed_files.back() == NULL) {
- cerr << argv[0] << ": protoc asked plugin to generate a file but "
- "did not provide a descriptor for the file: "
- << request.file_to_generate(i) << endl;
+ std::cerr << argv[0] << ": protoc asked plugin to generate a file but "
+ "did not provide a descriptor for the file: "
+ << request.file_to_generate(i) << std::endl;
return 1;
}
}
@@ -151,7 +152,7 @@ int PluginMain(int argc, char* argv[], const CodeGenerator* generator) {
}
if (!response.SerializeToFileDescriptor(STDOUT_FILENO)) {
- cerr << argv[0] << ": Error writing to stdout." << endl;
+ std::cerr << argv[0] << ": Error writing to stdout." << std::endl;
return 1;
}