diff options
Diffstat (limited to 'csharp/src')
4 files changed, 5 insertions, 6 deletions
diff --git a/csharp/src/ProtocolBuffers.Test/FieldPresenceTest.cs b/csharp/src/ProtocolBuffers.Test/FieldPresenceTest.cs index e0c07698..b607167e 100644 --- a/csharp/src/ProtocolBuffers.Test/FieldPresenceTest.cs +++ b/csharp/src/ProtocolBuffers.Test/FieldPresenceTest.cs @@ -163,7 +163,7 @@ namespace Google.ProtocolBuffers }
[Fact]
- public void TestSeralizeAndParse()
+ public void TestSerializeAndParse()
{
TestAllTypes.Builder builder = TestAllTypes.CreateBuilder();
builder.SetOptionalInt32(1234);
diff --git a/csharp/src/ProtocolBuffers/Descriptors/FileDescriptor.cs b/csharp/src/ProtocolBuffers/Descriptors/FileDescriptor.cs index 307e9dd7..fed032bf 100644 --- a/csharp/src/ProtocolBuffers/Descriptors/FileDescriptor.cs +++ b/csharp/src/ProtocolBuffers/Descriptors/FileDescriptor.cs @@ -56,13 +56,13 @@ namespace Google.ProtocolBuffers.Descriptors public enum ProtoSyntax
{
- PROTO2,
- PROTO3
+ Proto2,
+ Proto3
}
public ProtoSyntax Syntax
{
- get { return proto.Syntax == "proto3" ? ProtoSyntax.PROTO3 : ProtoSyntax.PROTO2; }
+ get { return proto.Syntax == "proto3" ? ProtoSyntax.Proto3 : ProtoSyntax.Proto2; }
}
private FileDescriptor(FileDescriptorProto proto, FileDescriptor[] dependencies, DescriptorPool pool, bool allowUnknownDependencies)
diff --git a/csharp/src/ProtocolBuffers/FieldAccess/FieldAccessorTable.cs b/csharp/src/ProtocolBuffers/FieldAccess/FieldAccessorTable.cs index d5c6c9cf..6e20b14e 100644 --- a/csharp/src/ProtocolBuffers/FieldAccess/FieldAccessorTable.cs +++ b/csharp/src/ProtocolBuffers/FieldAccess/FieldAccessorTable.cs @@ -68,7 +68,7 @@ namespace Google.ProtocolBuffers.FieldAccess {
this.descriptor = descriptor;
accessors = new IFieldAccessor<TMessage, TBuilder>[descriptor.Fields.Count];
- bool supportFieldPresence = descriptor.File.Syntax == FileDescriptor.ProtoSyntax.PROTO2;
+ bool supportFieldPresence = descriptor.File.Syntax == FileDescriptor.ProtoSyntax.Proto2;
for (int i = 0; i < accessors.Length; i++)
{
accessors[i] = CreateAccessor(descriptor.Fields[i], propertyNames[i], supportFieldPresence);
diff --git a/csharp/src/ProtocolBuffers/FieldAccess/SinglePrimitiveAccessor.cs b/csharp/src/ProtocolBuffers/FieldAccess/SinglePrimitiveAccessor.cs index df9dedaf..b9ab7293 100644 --- a/csharp/src/ProtocolBuffers/FieldAccess/SinglePrimitiveAccessor.cs +++ b/csharp/src/ProtocolBuffers/FieldAccess/SinglePrimitiveAccessor.cs @@ -43,7 +43,6 @@ namespace Google.ProtocolBuffers.FieldAccess where TBuilder : IBuilder<TMessage, TBuilder>
{
private readonly Type clrType;
- private readonly FieldDescriptor field;
private readonly Func<TMessage, object> getValueDelegate;
private readonly Action<TBuilder, object> setValueDelegate;
private readonly Func<TMessage, bool> hasDelegate;
|