summaryrefslogtreecommitdiff
path: root/tools/streaming_proto/cpp
diff options
context:
space:
mode:
authorYi Jin <jinyithu@google.com>2017-11-06 17:43:47 -0800
committerYi Jin <jinyithu@google.com>2017-11-14 10:54:24 -0800
commit0dfa752e67116940f04a988ca4a264f7140dd81f (patch)
tree3aa662e1d9da3143bc0c3a05bf5711d346c58601 /tools/streaming_proto/cpp
parenta379f499c8e27d2c18b7089feb18c7f0a44e0433 (diff)
Implement System Properties Section
Bug: 68774852 Test: unit tested and on device tests Change-Id: I0d4aadf8d4203fe56e35bbfb77e5c532116fd27e
Diffstat (limited to 'tools/streaming_proto/cpp')
-rw-r--r--tools/streaming_proto/cpp/main.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/streaming_proto/cpp/main.cpp b/tools/streaming_proto/cpp/main.cpp
index 9aef56270ee2..477902065f99 100644
--- a/tools/streaming_proto/cpp/main.cpp
+++ b/tools/streaming_proto/cpp/main.cpp
@@ -31,7 +31,7 @@ write_enum(stringstream& text, const EnumDescriptorProto& enu, const string& ind
text << indent << "// enum " << enu.name() << endl;
for (int i=0; i<N; i++) {
const EnumValueDescriptorProto& value = enu.value(i);
- text << indent << "const uint32_t "
+ text << indent << "const int "
<< make_constant_name(value.name())
<< " = " << value.number() << ";" << endl;
}
@@ -45,7 +45,7 @@ write_enum(stringstream& text, const EnumDescriptorProto& enu, const string& ind
text << indent << INDENT << "\"" << stripPrefix(enu.value(i).name(), prefix) << "\"," << endl;
}
text << indent << "};" << endl;
- text << indent << "const uint32_t _ENUM_" << name << "_VALUES[" << N << "] = {" << endl;
+ text << indent << "const int _ENUM_" << name << "_VALUES[" << N << "] = {" << endl;
for (int i=0; i<N; i++) {
text << indent << INDENT << make_constant_name(enu.value(i).name()) << "," << endl;
}