diff options
Diffstat (limited to 'src/ProtoGen/SourceGeneratorBase.cs')
-rw-r--r-- | src/ProtoGen/SourceGeneratorBase.cs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/ProtoGen/SourceGeneratorBase.cs b/src/ProtoGen/SourceGeneratorBase.cs index 6abe1dde..dea9def2 100644 --- a/src/ProtoGen/SourceGeneratorBase.cs +++ b/src/ProtoGen/SourceGeneratorBase.cs @@ -30,6 +30,10 @@ namespace Google.ProtocolBuffers.ProtoGen { } } + internal static string GetFieldConstantName(FieldDescriptor field) { + return NameHelpers.UnderscoresToPascalCase(GetFieldName(field)) + "FieldNumber"; + } + private static string ToCSharpName(string name, FileDescriptor file) { string result = file.CSharpOptions.Namespace; if (file.CSharpOptions.NestClasses) { |