diff options
author | Jon Skeet <jonskeet@google.com> | 2015-07-23 15:31:34 +0100 |
---|---|---|
committer | Jon Skeet <jonskeet@google.com> | 2015-07-27 07:47:50 +0100 |
commit | 0dbd5ec80d33ea2a37f5362a24fd72b2c5f51aaa (patch) | |
tree | 87757b73246b762cede87e54620ef78b791f2881 /csharp/src/Google.Protobuf/Reflection/OneofDescriptor.cs | |
parent | edff88886b03055f8dff0c0dad61d9450b59a23e (diff) | |
download | protobuf-0dbd5ec80d33ea2a37f5362a24fd72b2c5f51aaa.tar.gz protobuf-0dbd5ec80d33ea2a37f5362a24fd72b2c5f51aaa.tar.bz2 protobuf-0dbd5ec80d33ea2a37f5362a24fd72b2c5f51aaa.zip |
First attempt at using profile 259 for Google.Protobuf.
This requires .NET 4.5, and there are a few compatibility changes required around reflection.
Creating a PR from this to see how our CI systems handle it. Will want to add more documentation,
validation and probably tests before merging.
This is in aid of issue #590.
Diffstat (limited to 'csharp/src/Google.Protobuf/Reflection/OneofDescriptor.cs')
-rw-r--r-- | csharp/src/Google.Protobuf/Reflection/OneofDescriptor.cs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/csharp/src/Google.Protobuf/Reflection/OneofDescriptor.cs b/csharp/src/Google.Protobuf/Reflection/OneofDescriptor.cs index cd4c5534..8571a5eb 100644 --- a/csharp/src/Google.Protobuf/Reflection/OneofDescriptor.cs +++ b/csharp/src/Google.Protobuf/Reflection/OneofDescriptor.cs @@ -33,6 +33,7 @@ using System.Collections.Generic; using System.Collections.ObjectModel; using System.Linq; +using Google.Protobuf.Compatibility; namespace Google.Protobuf.Reflection { @@ -91,7 +92,7 @@ namespace Google.Protobuf.Reflection { throw new DescriptorValidationException(this, "Property " + clrName + "Case not found in " + containingType.GeneratedType); } - var clearMethod = containingType.GeneratedType.GetMethod("Clear" + clrName, ReflectionUtil.EmptyTypes); + var clearMethod = containingType.GeneratedType.GetMethod("Clear" + clrName); if (clearMethod == null) { throw new DescriptorValidationException(this, "Method Clear" + clrName + " not found in " + containingType.GeneratedType); |