aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/google/protobuf/compiler/cpp/cpp_enum.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/google/protobuf/compiler/cpp/cpp_enum.h')
-rw-r--r--src/google/protobuf/compiler/cpp/cpp_enum.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/google/protobuf/compiler/cpp/cpp_enum.h b/src/google/protobuf/compiler/cpp/cpp_enum.h
index 90edf001..0b568c57 100644
--- a/src/google/protobuf/compiler/cpp/cpp_enum.h
+++ b/src/google/protobuf/compiler/cpp/cpp_enum.h
@@ -66,7 +66,8 @@ class EnumGenerator {
// enums. A given key in enum_names will map from an enum class name to the
// EnumDescriptor that was responsible for its inclusion in the map. This can
// be used to associate the descriptor with the code generated for it.
- void FillForwardDeclaration(map<string, const EnumDescriptor*>* enum_names);
+ void FillForwardDeclaration(
+ std::map<string, const EnumDescriptor*>* enum_names);
// Generate header code defining the enum. This code should be placed
// within the enum's package namespace, but NOT within any class, even for
@@ -87,7 +88,7 @@ class EnumGenerator {
// Generate code that initializes the global variable storing the enum's
// descriptor.
- void GenerateDescriptorInitializer(io::Printer* printer, int index);
+ void GenerateDescriptorInitializer(io::Printer* printer);
// Generate non-inline methods related to the enum, such as IsValidValue().
// Goes in the .cc file.
@@ -100,6 +101,9 @@ class EnumGenerator {
// whether to generate the *_ARRAYSIZE constant.
const bool generate_array_size_;
+ int index_in_metadata_;
+
+ friend class FileGenerator;
GOOGLE_DISALLOW_EVIL_CONSTRUCTORS(EnumGenerator);
};