From 3bbe401069272bea0e6533157953b8d925318e87 Mon Sep 17 00:00:00 2001 From: Chad Walters Date: Mon, 26 Jun 2017 15:10:40 -0700 Subject: [PATCH] [C#] Remove support for .NET 4.0 --- CHANGELOG.md | 2 + appveyor.yml | 3 - cmake/Config.cmake | 6 +- cs/build/internal/Common.Internal.props | 5 - cs/build/internal/Common.Internal.targets | 1 - cs/nuget/bond.compiler.csharp.nuspec | 5 - cs/nuget/bond.core.csharp.nuspec | 13 -- cs/nuget/bond.runtime.csharp.nuspec | 4 - .../epoxy-transport/epoxy-transport.csproj | 1 - cs/src/comm/interfaces/interfaces.csproj | 1 - cs/src/comm/layers/layers.csproj | 1 - cs/src/comm/service/service.csproj | 1 - .../simpleinmem-transport.csproj | 1 - cs/src/core/Audit.cs | 4 - cs/src/core/io/IntegerHelper.cs | 12 -- cs/src/core/protocols/CompactBinary.cs | 100 --------------- cs/src/core/protocols/CompactBinaryCounter.cs | 50 -------- cs/src/core/protocols/FastBinary.cs | 100 --------------- cs/src/core/protocols/SimpleBinary.cs | 120 ------------------ cs/src/core/protocols/SimpleXmlReader.cs | 4 - cs/src/core/protocols/SimpleXmlWriter.cs | 50 -------- cs/src/grpc/grpc.csproj | 1 - cs/src/json/JSON.csproj | 3 - cs/src/json/protocols/SimpleJsonReader.cs | 4 +- cs/src/json/protocols/SimpleJsonWriter.cs | 40 ------ cs/src/reflection/Reflection40.cs | 62 --------- cs/src/reflection/Reflection45.cs | 5 - cs/src/reflection/reflection.csproj | 1 - .../codegen/no-warnings/no-warnings.csproj | 2 +- .../output-no-slash/output-no-slash.csproj | 2 +- cs/test/comm/comm.csproj | 6 +- .../comm/client/CommCompatClient.csproj | 1 - .../comm/server/CommCompatServer.csproj | 1 - .../comm/shared/CommCompatShared.csproj | 1 - .../grpc/client/GrpcCompatClient.csproj | 1 - .../grpc/server/GrpcCompatServer.csproj | 1 - .../grpc/shared/GrpcCompatShared.csproj | 1 - cs/test/core/Core.csproj | 10 +- cs/test/grpc/grpc.csproj | 1 - doc/src/bond_cs.md | 16 +-- 40 files changed, 19 insertions(+), 624 deletions(-) delete mode 100644 cs/src/reflection/Reflection40.cs diff --git a/CHANGELOG.md b/CHANGELOG.md index 02735fcd..3e444fb4 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -80,6 +80,8 @@ get a compiler error. To fix, remove the `` part: ### C# ### +* **Breaking change** Support for .NET 4.0 has been dropped from the + [supported frameworks](https://microsoft.github.io/bond/manual/bond_cs.html#frameworks-targeted). * **Breaking change** The deprecated type `Bond.BondReflection` has been removed. The type `Bond.Reflection` should be used instead. * **Breaking change** Bond assemblies are now diff --git a/appveyor.yml b/appveyor.yml index 3eea9acc..f51e6cf3 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -295,9 +295,6 @@ if ($env:BOND_BUILD -eq "C#") { - nunit-console-x86 /framework:net-4.0 /labels "cs\test\core\bin\debug\net40\${env:BOND_OUTPUT}\Bond.UnitTest.dll" cs\test\internal\bin\debug\net40\Bond.InternalTest.dll - if (-not $?) { throw "tests failed" } - nunit-console-x86 /framework:net-4.5 /labels "cs\test\core\bin\debug\net45\${env:BOND_OUTPUT}\Bond.UnitTest.dll" cs\test\internal\bin\debug\net45\Bond.InternalTest.dll if (-not $?) { throw "tests failed" } diff --git a/cmake/Config.cmake b/cmake/Config.cmake index e4f35467..d5125c70 100644 --- a/cmake/Config.cmake +++ b/cmake/Config.cmake @@ -54,21 +54,21 @@ if (WIN32) # If C# has been built we will also run C# compatibility tests find_program (BOND_CSHARP_COMPAT_TEST Bond.CompatibilityTest.exe - PATH_SUFFIXES net40 net45 + PATH_SUFFIXES net45 NO_DEFAULT_PATH PATHS "${CMAKE_CURRENT_SOURCE_DIR}/cs/test/compat/core/bin/debug" "${CMAKE_CURRENT_SOURCE_DIR}/cs/test/compat/core/bin/retail") find_program (BOND_CSHARP_COMM_COMPAT_SERVER CommCompatServer.exe - PATH_SUFFIXES net40 net45 + PATH_SUFFIXES net45 NO_DEFAULT_PATH PATHS "${CMAKE_CURRENT_SOURCE_DIR}/cs/test/compat/comm/server/bin/debug" "${CMAKE_CURRENT_SOURCE_DIR}/cs/test/compat/comm/server/bin/retail") find_program (BOND_CSHARP_COMM_COMPAT_CLIENT CommCompatClient.exe - PATH_SUFFIXES net40 net45 + PATH_SUFFIXES net45 NO_DEFAULT_PATH PATHS "${CMAKE_CURRENT_SOURCE_DIR}/cs/test/compat/comm/client/bin/debug" diff --git a/cs/build/internal/Common.Internal.props b/cs/build/internal/Common.Internal.props index 0a317bfb..397a20ec 100644 --- a/cs/build/internal/Common.Internal.props +++ b/cs/build/internal/Common.Internal.props @@ -12,11 +12,6 @@ v4.5 net45 - $(DefineConstants);NET45 - - - v4.0 - $(DefineConstants);NET40 bin\$(BuildType)\$(BuildFramework) diff --git a/cs/build/internal/Common.Internal.targets b/cs/build/internal/Common.Internal.targets index a5be9233..de54c69a 100644 --- a/cs/build/internal/Common.Internal.targets +++ b/cs/build/internal/Common.Internal.targets @@ -18,6 +18,5 @@ - diff --git a/cs/nuget/bond.compiler.csharp.nuspec b/cs/nuget/bond.compiler.csharp.nuspec index 2c2760cc..d1b5b3f5 100644 --- a/cs/nuget/bond.compiler.csharp.nuspec +++ b/cs/nuget/bond.compiler.csharp.nuspec @@ -26,11 +26,6 @@ files, but there doesn't seem to be a good way to reference dependent packages from MSBuild targets. Instead, we duplicate the files in this package. They're pretty small. --> - - - - - diff --git a/cs/nuget/bond.core.csharp.nuspec b/cs/nuget/bond.core.csharp.nuspec index f8d9e6e6..25df858d 100644 --- a/cs/nuget/bond.core.csharp.nuspec +++ b/cs/nuget/bond.core.csharp.nuspec @@ -24,19 +24,6 @@ Bond .NET C# serialization - - - - - - - - - - - - - diff --git a/cs/nuget/bond.runtime.csharp.nuspec b/cs/nuget/bond.runtime.csharp.nuspec index d0991cb2..dae4b392 100644 --- a/cs/nuget/bond.runtime.csharp.nuspec +++ b/cs/nuget/bond.runtime.csharp.nuspec @@ -28,10 +28,6 @@ - - - - diff --git a/cs/src/comm/epoxy-transport/epoxy-transport.csproj b/cs/src/comm/epoxy-transport/epoxy-transport.csproj index 44d9bb46..81cf6b0d 100644 --- a/cs/src/comm/epoxy-transport/epoxy-transport.csproj +++ b/cs/src/comm/epoxy-transport/epoxy-transport.csproj @@ -10,7 +10,6 @@ Bond.Comm.Epoxy Bond.Comm.Epoxy true - true diff --git a/cs/src/comm/interfaces/interfaces.csproj b/cs/src/comm/interfaces/interfaces.csproj index e411190d..133cc797 100644 --- a/cs/src/comm/interfaces/interfaces.csproj +++ b/cs/src/comm/interfaces/interfaces.csproj @@ -10,7 +10,6 @@ Bond.Comm Bond.Comm.Interfaces true - true diff --git a/cs/src/comm/layers/layers.csproj b/cs/src/comm/layers/layers.csproj index f810d2c0..902eb0e2 100644 --- a/cs/src/comm/layers/layers.csproj +++ b/cs/src/comm/layers/layers.csproj @@ -10,7 +10,6 @@ Bond.Comm.Layers Bond.Comm.Layers true - true diff --git a/cs/src/comm/service/service.csproj b/cs/src/comm/service/service.csproj index ba812eb2..2f32f93b 100644 --- a/cs/src/comm/service/service.csproj +++ b/cs/src/comm/service/service.csproj @@ -10,7 +10,6 @@ Bond.Comm.Service Bond.Comm.Service true - true diff --git a/cs/src/comm/simpleinmem-transport/simpleinmem-transport.csproj b/cs/src/comm/simpleinmem-transport/simpleinmem-transport.csproj index cdadba7d..b8a4d404 100644 --- a/cs/src/comm/simpleinmem-transport/simpleinmem-transport.csproj +++ b/cs/src/comm/simpleinmem-transport/simpleinmem-transport.csproj @@ -10,7 +10,6 @@ Bond.Comm.SimpleInMem Bond.Comm.SimpleInMem true - true diff --git a/cs/src/core/Audit.cs b/cs/src/core/Audit.cs index f007d1d0..b6c57cf9 100644 --- a/cs/src/core/Audit.cs +++ b/cs/src/core/Audit.cs @@ -20,9 +20,7 @@ namespace Bond throw new ArgumentException(message); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public static void ArgNotNull(object value, string paramName) { if (value == null) @@ -31,9 +29,7 @@ namespace Bond } } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public static void ArgRule(bool invariant, string message) { if (!invariant) diff --git a/cs/src/core/io/IntegerHelper.cs b/cs/src/core/io/IntegerHelper.cs index 2a355a05..2aaec97d 100644 --- a/cs/src/core/io/IntegerHelper.cs +++ b/cs/src/core/io/IntegerHelper.cs @@ -326,49 +326,37 @@ namespace Bond.IO return result; } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public static UInt16 EncodeZigzag16(Int16 value) { return (UInt16)((value << 1) ^ (value >> (sizeof(Int16) * 8 - 1))); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public static UInt32 EncodeZigzag32(Int32 value) { return (UInt32)((value << 1) ^ (value >> (sizeof(Int32) * 8 - 1))); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public static UInt64 EncodeZigzag64(Int64 value) { return (UInt64)((value << 1) ^ (value >> (sizeof(Int64) * 8 - 1))); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public static Int16 DecodeZigzag16(UInt16 value) { return (Int16)((value >> 1) ^ (-(value & 1))); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public static Int32 DecodeZigzag32(UInt32 value) { return (Int32)((value >> 1) ^ (-(value & 1))); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public static Int64 DecodeZigzag64(UInt64 value) { return (Int64)((value >> 1) ^ (UInt64)(-(Int64)(value & 1))); diff --git a/cs/src/core/protocols/CompactBinary.cs b/cs/src/core/protocols/CompactBinary.cs index eb44bb9b..eb29de0c 100644 --- a/cs/src/core/protocols/CompactBinary.cs +++ b/cs/src/core/protocols/CompactBinary.cs @@ -185,9 +185,7 @@ namespace Bond.Protocols /// /// Write protocol magic number and version /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteVersion() { output.WriteUInt16(Magic); @@ -199,9 +197,7 @@ namespace Bond.Protocols /// Start writing a struct /// /// Schema metadata -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructBegin(Metadata metadata) { if (version == 2) @@ -218,18 +214,14 @@ namespace Bond.Protocols /// Start writing a base struct /// /// Base schema metadata -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseBegin(Metadata metadata) {} /// /// End writing a struct /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructEnd() { output.WriteUInt8((Byte)BondDataType.BT_STOP); @@ -239,9 +231,7 @@ namespace Bond.Protocols /// /// End writing a base struct /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseEnd() { output.WriteUInt8((Byte)BondDataType.BT_STOP_BASE); @@ -253,9 +243,7 @@ namespace Bond.Protocols /// Type of the field /// Identifier of the field /// Metadata of the field -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldBegin(BondDataType type, ushort id, Metadata metadata) { var fieldType = (uint)type; @@ -281,9 +269,7 @@ namespace Bond.Protocols /// Type of the field /// Identifier of the field /// Metadata of the field -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldOmitted(BondDataType dataType, ushort id, Metadata metadata) {} @@ -291,9 +277,7 @@ namespace Bond.Protocols /// /// End writing a field /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldEnd() {} @@ -302,9 +286,7 @@ namespace Bond.Protocols /// /// Number of elements in the container /// Type of the elements -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerBegin(int count, BondDataType elementType) { if (2 == version && count < 7) @@ -324,9 +306,7 @@ namespace Bond.Protocols /// Number of elements in the container /// Type of the keys /// /// Type of the values -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerBegin(int count, BondDataType keyType, BondDataType valueType) { output.WriteUInt8((byte)keyType); @@ -337,18 +317,14 @@ namespace Bond.Protocols /// /// End writing a container /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerEnd() {} /// /// Write array of bytes verbatim /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBytes(ArraySegment data) { output.WriteBytes(data); @@ -360,9 +336,7 @@ namespace Bond.Protocols /// /// Write an UInt8 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt8(Byte value) { output.WriteUInt8(value); @@ -371,9 +345,7 @@ namespace Bond.Protocols /// /// Write an UInt16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt16(UInt16 value) { output.WriteVarUInt16(value); @@ -382,9 +354,7 @@ namespace Bond.Protocols /// /// Write an UInt16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt32(UInt32 value) { output.WriteVarUInt32(value); @@ -393,9 +363,7 @@ namespace Bond.Protocols /// /// Write an UInt64 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt64(UInt64 value) { output.WriteVarUInt64(value); @@ -404,9 +372,7 @@ namespace Bond.Protocols /// /// Write an Int8 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt8(SByte value) { output.WriteUInt8((Byte)value); @@ -415,9 +381,7 @@ namespace Bond.Protocols /// /// Write an Int16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt16(Int16 value) { output.WriteVarUInt16(IntegerHelper.EncodeZigzag16(value)); @@ -426,9 +390,7 @@ namespace Bond.Protocols /// /// Write an Int32 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt32(Int32 value) { output.WriteVarUInt32(IntegerHelper.EncodeZigzag32(value)); @@ -437,9 +399,7 @@ namespace Bond.Protocols /// /// Write an Int64 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt64(Int64 value) { output.WriteVarUInt64(IntegerHelper.EncodeZigzag64(value)); @@ -448,9 +408,7 @@ namespace Bond.Protocols /// /// Write a float /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFloat(float value) { output.WriteFloat(value); @@ -459,9 +417,7 @@ namespace Bond.Protocols /// /// Write a double /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteDouble(double value) { output.WriteDouble(value); @@ -470,9 +426,7 @@ namespace Bond.Protocols /// /// Write a bool /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBool(bool value) { output.WriteUInt8((byte)(value ? 1 : 0)); @@ -481,9 +435,7 @@ namespace Bond.Protocols /// /// Write a UTF-8 string /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteString(string value) { if (value.Length == 0) @@ -501,9 +453,7 @@ namespace Bond.Protocols /// /// Write a UTF-16 string /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteWString(string value) { if (value.Length == 0) @@ -572,17 +522,13 @@ namespace Bond.Protocols /// /// Clone the reader /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif CompactBinaryReader ICloneable>.Clone() { return new CompactBinaryReader(input.Clone(), version); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif IClonableTaggedProtocolReader ICloneable.Clone() { return (this as ICloneable>).Clone(); @@ -594,9 +540,7 @@ namespace Bond.Protocols /// Start reading a struct /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadStructBegin() { if (2 == version) @@ -609,9 +553,7 @@ namespace Bond.Protocols /// Start reading a base of a struct /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadBaseBegin() { } @@ -619,9 +561,7 @@ namespace Bond.Protocols /// End reading a struct /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadStructEnd() { } @@ -629,9 +569,7 @@ namespace Bond.Protocols /// End reading a base of a struct /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadBaseEnd() { } @@ -642,9 +580,7 @@ namespace Bond.Protocols /// or BT_STOP/BT_STOP_BASE if there is no more fields in current struct/base /// Out parameter set to the field identifier /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadFieldBegin(out BondDataType type, out ushort id) { uint raw = input.ReadUInt8(); @@ -670,9 +606,7 @@ namespace Bond.Protocols /// End reading a field /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadFieldEnd() { } @@ -682,9 +616,7 @@ namespace Bond.Protocols /// An out parameter set to number of items in the container /// An out parameter set to type of container elements /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadContainerBegin(out int count, out BondDataType elementType) { var raw = input.ReadUInt8(); @@ -703,9 +635,7 @@ namespace Bond.Protocols /// An out parameter set to the type of map keys /// An out parameter set to the type of map values /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadContainerBegin(out int count, out BondDataType keyType, out BondDataType valueType) { keyType = (BondDataType)input.ReadUInt8(); @@ -717,9 +647,7 @@ namespace Bond.Protocols /// End reading a container /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadContainerEnd() { } @@ -731,9 +659,7 @@ namespace Bond.Protocols /// Read an UInt8 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public byte ReadUInt8() { return input.ReadUInt8(); @@ -743,9 +669,7 @@ namespace Bond.Protocols /// Read an UInt16 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public ushort ReadUInt16() { return input.ReadVarUInt16(); @@ -755,9 +679,7 @@ namespace Bond.Protocols /// Read an UInt32 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public uint ReadUInt32() { return input.ReadVarUInt32(); @@ -767,9 +689,7 @@ namespace Bond.Protocols /// Read an UInt64 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public UInt64 ReadUInt64() { return input.ReadVarUInt64(); @@ -779,9 +699,7 @@ namespace Bond.Protocols /// Read an Int8 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public sbyte ReadInt8() { return (sbyte)input.ReadUInt8(); @@ -791,9 +709,7 @@ namespace Bond.Protocols /// Read an Int16 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public short ReadInt16() { return IntegerHelper.DecodeZigzag16(input.ReadVarUInt16()); @@ -803,9 +719,7 @@ namespace Bond.Protocols /// Read an Int32 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public int ReadInt32() { return IntegerHelper.DecodeZigzag32(input.ReadVarUInt32()); @@ -815,9 +729,7 @@ namespace Bond.Protocols /// Read an Int64 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public Int64 ReadInt64() { return IntegerHelper.DecodeZigzag64(input.ReadVarUInt64()); @@ -827,9 +739,7 @@ namespace Bond.Protocols /// Read a bool /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public bool ReadBool() { return input.ReadUInt8() != 0; @@ -839,9 +749,7 @@ namespace Bond.Protocols /// Read a float /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public float ReadFloat() { return input.ReadFloat(); @@ -851,9 +759,7 @@ namespace Bond.Protocols /// Read a double /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public double ReadDouble() { return input.ReadDouble(); @@ -863,9 +769,7 @@ namespace Bond.Protocols /// Read a UTF-8 string /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public String ReadString() { var length = (int)input.ReadVarUInt32(); @@ -876,9 +780,7 @@ namespace Bond.Protocols /// Read a UTF-16 string /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public string ReadWString() { var length = (int)input.ReadVarUInt32(); @@ -890,9 +792,7 @@ namespace Bond.Protocols /// /// Number of bytes to read /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public ArraySegment ReadBytes(int count) { return input.ReadBytes(count); diff --git a/cs/src/core/protocols/CompactBinaryCounter.cs b/cs/src/core/protocols/CompactBinaryCounter.cs index 3d231046..94288a86 100644 --- a/cs/src/core/protocols/CompactBinaryCounter.cs +++ b/cs/src/core/protocols/CompactBinaryCounter.cs @@ -68,9 +68,7 @@ namespace Bond.Protocols /// /// Write protocol magic number and version /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteVersion() { } @@ -80,9 +78,7 @@ namespace Bond.Protocols /// Start writing a struct /// /// Schema metadata -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructBegin(Metadata metadata) { LinkedListNode frameNode = lengths.AddLast(0); @@ -92,9 +88,7 @@ namespace Bond.Protocols /// /// End writing a struct /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructEnd() { CounterStackFrame frame = counterStack.Peek(); @@ -113,18 +107,14 @@ namespace Bond.Protocols /// Start writing a base struct /// /// Base schema metadata -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseBegin(Metadata metadata) { } /// /// End writing a base struct /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseEnd() { AddBytes(1); @@ -136,9 +126,7 @@ namespace Bond.Protocols /// Type of the field /// Identifier of the field /// Metadata of the field -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldBegin(BondDataType type, ushort id, Metadata metadata) { if (id <= 5) @@ -161,9 +149,7 @@ namespace Bond.Protocols /// Type of the field /// Identifier of the field /// Metadata of the field -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldOmitted(BondDataType dataType, ushort id, Metadata metadata) { } @@ -171,9 +157,7 @@ namespace Bond.Protocols /// /// End writing a field /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldEnd() { } @@ -182,9 +166,7 @@ namespace Bond.Protocols /// /// Number of elements in the container /// Type of the elements -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerBegin(int count, BondDataType elementType) { if (count < 7) @@ -204,9 +186,7 @@ namespace Bond.Protocols /// Number of elements in the container /// Type of the keys /// Type of the values -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerBegin(int count, BondDataType keyType, BondDataType valueType) { AddBytes(2); @@ -216,18 +196,14 @@ namespace Bond.Protocols /// /// End writing a container /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerEnd() { } /// /// Write array of bytes verbatim /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBytes(ArraySegment data) { AddBytes(data.Count); @@ -239,9 +215,7 @@ namespace Bond.Protocols /// /// Write an UInt8 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt8(byte value) { AddBytes(1); @@ -250,9 +224,7 @@ namespace Bond.Protocols /// /// Write an UInt16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt16(UInt16 value) { AddVarUInt16(value); @@ -261,9 +233,7 @@ namespace Bond.Protocols /// /// Write an UInt16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt32(UInt32 value) { AddVarUInt32(value); @@ -272,9 +242,7 @@ namespace Bond.Protocols /// /// Write an UInt64 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt64(UInt64 value) { AddVarUInt64(value); @@ -283,9 +251,7 @@ namespace Bond.Protocols /// /// Write an Int8 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt8(SByte value) { AddBytes(1); @@ -294,9 +260,7 @@ namespace Bond.Protocols /// /// Write an Int16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt16(Int16 value) { AddVarUInt16(IntegerHelper.EncodeZigzag16(value)); @@ -305,9 +269,7 @@ namespace Bond.Protocols /// /// Write an Int32 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt32(Int32 value) { AddVarUInt32(IntegerHelper.EncodeZigzag32(value)); @@ -316,9 +278,7 @@ namespace Bond.Protocols /// /// Write an Int64 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt64(Int64 value) { AddVarUInt64(IntegerHelper.EncodeZigzag64(value)); @@ -327,9 +287,7 @@ namespace Bond.Protocols /// /// Write a float /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFloat(float value) { AddBytes(4); @@ -338,9 +296,7 @@ namespace Bond.Protocols /// /// Write a double /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteDouble(double value) { AddBytes(8); @@ -349,9 +305,7 @@ namespace Bond.Protocols /// /// Write a bool /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBool(bool value) { AddBytes(1); @@ -360,9 +314,7 @@ namespace Bond.Protocols /// /// Write a UTF-8 string /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteString(string value) { int size = Encoding.UTF8.GetByteCount(value); @@ -373,9 +325,7 @@ namespace Bond.Protocols /// /// Write a UTF-16 string /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteWString(string value) { AddVarUInt32((uint)value.Length); diff --git a/cs/src/core/protocols/FastBinary.cs b/cs/src/core/protocols/FastBinary.cs index 9cbba79f..28548352 100644 --- a/cs/src/core/protocols/FastBinary.cs +++ b/cs/src/core/protocols/FastBinary.cs @@ -119,9 +119,7 @@ namespace Bond.Protocols /// /// Write protocol magic number and version /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteVersion() { output.WriteUInt16(Magic); @@ -133,9 +131,7 @@ namespace Bond.Protocols /// Start writing a struct /// /// Schema metadata -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructBegin(Metadata metadata) {} @@ -143,18 +139,14 @@ namespace Bond.Protocols /// Start writing a base struct /// /// Base schema metadata -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseBegin(Metadata metadata) {} /// /// End writing a struct /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructEnd() { output.WriteUInt8((Byte)BondDataType.BT_STOP); @@ -163,9 +155,7 @@ namespace Bond.Protocols /// /// End writing a base struct /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseEnd() { output.WriteUInt8((Byte)BondDataType.BT_STOP_BASE); @@ -177,9 +167,7 @@ namespace Bond.Protocols /// Type of the field /// Identifier of the field /// Metadata of the field -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldBegin(BondDataType type, ushort id, Metadata metadata) { output.WriteUInt8((byte) type); @@ -193,9 +181,7 @@ namespace Bond.Protocols /// Type of the field /// Identifier of the field /// Metadata of the field -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldOmitted(BondDataType dataType, ushort id, Metadata metadata) {} @@ -203,9 +189,7 @@ namespace Bond.Protocols /// /// End writing a field /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldEnd() {} @@ -214,9 +198,7 @@ namespace Bond.Protocols /// /// Number of elements in the container /// Type of the elements -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerBegin(int count, BondDataType elementType) { output.WriteUInt8((byte)elementType); @@ -229,9 +211,7 @@ namespace Bond.Protocols /// Number of elements in the container /// Type of the keys /// /// Type of the values -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerBegin(int count, BondDataType keyType, BondDataType valueType) { output.WriteUInt8((byte)keyType); @@ -242,18 +222,14 @@ namespace Bond.Protocols /// /// End writing a container /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerEnd() {} /// /// Write array of bytes verbatim /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBytes(ArraySegment data) { output.WriteBytes(data); @@ -265,9 +241,7 @@ namespace Bond.Protocols /// /// Write an UInt8 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt8(Byte value) { output.WriteUInt8(value); @@ -276,9 +250,7 @@ namespace Bond.Protocols /// /// Write an UInt16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt16(UInt16 value) { output.WriteUInt16(value); @@ -287,9 +259,7 @@ namespace Bond.Protocols /// /// Write an UInt16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt32(UInt32 value) { output.WriteUInt32(value); @@ -298,9 +268,7 @@ namespace Bond.Protocols /// /// Write an UInt64 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt64(UInt64 value) { output.WriteUInt64(value); @@ -309,9 +277,7 @@ namespace Bond.Protocols /// /// Write an Int8 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt8(SByte value) { output.WriteUInt8((Byte)value); @@ -320,9 +286,7 @@ namespace Bond.Protocols /// /// Write an Int16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt16(Int16 value) { output.WriteUInt16((ushort)value); @@ -331,9 +295,7 @@ namespace Bond.Protocols /// /// Write an Int32 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt32(Int32 value) { output.WriteUInt32((uint)value); @@ -342,9 +304,7 @@ namespace Bond.Protocols /// /// Write an Int64 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt64(Int64 value) { output.WriteUInt64((ulong)value); @@ -353,9 +313,7 @@ namespace Bond.Protocols /// /// Write a float /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFloat(float value) { output.WriteFloat(value); @@ -364,9 +322,7 @@ namespace Bond.Protocols /// /// Write a double /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteDouble(double value) { output.WriteDouble(value); @@ -375,9 +331,7 @@ namespace Bond.Protocols /// /// Write a bool /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBool(bool value) { output.WriteUInt8((byte)(value ? 1 : 0)); @@ -386,9 +340,7 @@ namespace Bond.Protocols /// /// Write a UTF-8 string /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteString(string value) { if (value.Length == 0) @@ -406,9 +358,7 @@ namespace Bond.Protocols /// /// Write a UTF-16 string /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteWString(string value) { if (value.Length == 0) @@ -446,17 +396,13 @@ namespace Bond.Protocols /// /// Clone the reader /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif FastBinaryReader ICloneable>.Clone() { return new FastBinaryReader(input.Clone()); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif IClonableTaggedProtocolReader ICloneable.Clone() { return (this as ICloneable>).Clone(); @@ -468,9 +414,7 @@ namespace Bond.Protocols /// Start reading a struct /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadStructBegin() { } @@ -478,9 +422,7 @@ namespace Bond.Protocols /// Start reading a base of a struct /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadBaseBegin() { } @@ -488,9 +430,7 @@ namespace Bond.Protocols /// End reading a struct /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadStructEnd() { } @@ -498,9 +438,7 @@ namespace Bond.Protocols /// End reading a base of a struct /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadBaseEnd() { } @@ -511,9 +449,7 @@ namespace Bond.Protocols /// or BT_STOP/BT_STOP_BASE if there is no more fields in current struct/base /// Out parameter set to the field identifier /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadFieldBegin(out BondDataType type, out ushort id) { type = (BondDataType)input.ReadUInt8(); @@ -528,9 +464,7 @@ namespace Bond.Protocols /// End reading a field /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadFieldEnd() { } @@ -540,9 +474,7 @@ namespace Bond.Protocols /// An out parameter set to number of items in the container /// An out parameter set to type of container elements /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadContainerBegin(out int count, out BondDataType elementType) { elementType = (BondDataType)input.ReadUInt8(); @@ -556,9 +488,7 @@ namespace Bond.Protocols /// An out parameter set to the type of map keys /// An out parameter set to the type of map values /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadContainerBegin(out int count, out BondDataType keyType, out BondDataType valueType) { keyType = (BondDataType)input.ReadUInt8(); @@ -570,9 +500,7 @@ namespace Bond.Protocols /// End reading a container /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadContainerEnd() { } @@ -584,9 +512,7 @@ namespace Bond.Protocols /// Read an UInt8 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public byte ReadUInt8() { return input.ReadUInt8(); @@ -596,9 +522,7 @@ namespace Bond.Protocols /// Read an UInt16 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public ushort ReadUInt16() { return input.ReadUInt16(); @@ -608,9 +532,7 @@ namespace Bond.Protocols /// Read an UInt32 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public uint ReadUInt32() { return input.ReadUInt32(); @@ -620,9 +542,7 @@ namespace Bond.Protocols /// Read an UInt64 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public UInt64 ReadUInt64() { return input.ReadUInt64(); @@ -632,9 +552,7 @@ namespace Bond.Protocols /// Read an Int8 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public sbyte ReadInt8() { return (sbyte)input.ReadUInt8(); @@ -644,9 +562,7 @@ namespace Bond.Protocols /// Read an Int16 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public short ReadInt16() { return (short)input.ReadUInt16(); @@ -656,9 +572,7 @@ namespace Bond.Protocols /// Read an Int32 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public int ReadInt32() { return (int)input.ReadUInt32(); @@ -668,9 +582,7 @@ namespace Bond.Protocols /// Read an Int64 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public long ReadInt64() { return (long)input.ReadUInt64(); @@ -680,9 +592,7 @@ namespace Bond.Protocols /// Read a bool /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public bool ReadBool() { return input.ReadUInt8() != 0; @@ -692,9 +602,7 @@ namespace Bond.Protocols /// Read a float /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public float ReadFloat() { return input.ReadFloat(); @@ -704,9 +612,7 @@ namespace Bond.Protocols /// Read a double /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public double ReadDouble() { return input.ReadDouble(); @@ -716,9 +622,7 @@ namespace Bond.Protocols /// Read a UTF-8 string /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public String ReadString() { var length = (int)input.ReadVarUInt32(); @@ -729,9 +633,7 @@ namespace Bond.Protocols /// Read a UTF-16 string /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public string ReadWString() { var length = (int)input.ReadVarUInt32(); @@ -743,9 +645,7 @@ namespace Bond.Protocols /// /// Number of bytes to read /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public ArraySegment ReadBytes(int count) { return input.ReadBytes(count); diff --git a/cs/src/core/protocols/SimpleBinary.cs b/cs/src/core/protocols/SimpleBinary.cs index d6f59623..ad43f8f7 100644 --- a/cs/src/core/protocols/SimpleBinary.cs +++ b/cs/src/core/protocols/SimpleBinary.cs @@ -85,9 +85,7 @@ namespace Bond.Protocols /// /// Write protocol magic number and version /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteVersion() { output.WriteUInt16(Magic); @@ -97,34 +95,22 @@ namespace Bond.Protocols #region Complex Types #region Unused in tagged protocol -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldBegin(BondDataType type, ushort id, Metadata metadata) { } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldEnd() { } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructBegin(Metadata metadata) { } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseBegin(Metadata metadata) { } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructEnd() { } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseEnd() { } #endregion @@ -135,9 +121,7 @@ namespace Bond.Protocols /// Type of the field /// Identifier of the field /// Metadata of the field -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldOmitted(BondDataType dataType, ushort id, Metadata metadata) { // Simple doesn't support omitting fields so instead we write the default value @@ -200,9 +184,7 @@ namespace Bond.Protocols /// /// Number of elements in the container /// Type of the elements -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerBegin(int count, BondDataType elementType) { WriteLength(count); @@ -214,9 +196,7 @@ namespace Bond.Protocols /// Number of elements in the container /// Type of the keys /// /// Type of the values -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerBegin(int count, BondDataType keyType, BondDataType valueType) { WriteLength(count); @@ -225,9 +205,7 @@ namespace Bond.Protocols /// /// End writing a container /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerEnd() { } #endregion @@ -236,9 +214,7 @@ namespace Bond.Protocols /// /// Write an UInt8 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt8(Byte value) { output.WriteUInt8(value); @@ -247,9 +223,7 @@ namespace Bond.Protocols /// /// Write an UInt16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt16(UInt16 value) { output.WriteUInt16(value); @@ -258,9 +232,7 @@ namespace Bond.Protocols /// /// Write an UInt32 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt32(UInt32 value) { output.WriteUInt32(value); @@ -269,9 +241,7 @@ namespace Bond.Protocols /// /// Write an UInt64 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt64(UInt64 value) { output.WriteUInt64(value); @@ -280,9 +250,7 @@ namespace Bond.Protocols /// /// Write array of bytes verbatim /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBytes(ArraySegment data) { output.WriteBytes(data); @@ -291,9 +259,7 @@ namespace Bond.Protocols /// /// Write an Int8 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt8(SByte value) { output.WriteUInt8(unchecked((Byte)value)); @@ -302,9 +268,7 @@ namespace Bond.Protocols /// /// Write an Int16 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt16(Int16 value) { output.WriteUInt16(unchecked((UInt16) value)); @@ -313,9 +277,7 @@ namespace Bond.Protocols /// /// Write an Int32 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt32(Int32 value) { output.WriteUInt32(unchecked((UInt32)value)); @@ -324,9 +286,7 @@ namespace Bond.Protocols /// /// Write an Int64 /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt64(Int64 value) { output.WriteUInt64(unchecked((UInt64)value)); @@ -335,9 +295,7 @@ namespace Bond.Protocols /// /// Write a float /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFloat(float value) { output.WriteFloat(value); @@ -346,9 +304,7 @@ namespace Bond.Protocols /// /// Write a double /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteDouble(double value) { output.WriteDouble(value); @@ -356,9 +312,7 @@ namespace Bond.Protocols /// write bool, extending the stream if necessary and possible /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBool(bool value) { output.WriteUInt8((byte)(value ? 1 : 0)); @@ -367,9 +321,7 @@ namespace Bond.Protocols /// /// Write a UTF-8 string /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteString(string value) { if (value.Length == 0) @@ -387,9 +339,7 @@ namespace Bond.Protocols /// /// Write a UTF-16 string /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteWString(string value) { if (value.Length == 0) @@ -404,9 +354,7 @@ namespace Bond.Protocols } #endregion -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif void WriteLength(int value) { if (version == 2) @@ -429,17 +377,13 @@ namespace Bond.Protocols this.version = version; } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif SimpleBinaryReader ICloneable>.Clone() { return new SimpleBinaryReader(input.Clone(), version); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif IClonableUntaggedProtocolReader ICloneable.Clone() { return (this as ICloneable>).Clone(); @@ -447,9 +391,7 @@ namespace Bond.Protocols #region Complex types -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public bool ReadFieldOmitted() { return false; @@ -460,9 +402,7 @@ namespace Bond.Protocols /// /// Number of elements /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public int ReadContainerBegin() { return ReadLength(); @@ -472,9 +412,7 @@ namespace Bond.Protocols /// End reading a container /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void ReadContainerEnd() {} @@ -486,17 +424,13 @@ namespace Bond.Protocols /// Read an UInt8 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public byte ReadUInt8() { return input.ReadUInt8(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipUInt8() { input.SkipBytes(1); @@ -506,17 +440,13 @@ namespace Bond.Protocols /// Read an UInt16 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public ushort ReadUInt16() { return input.ReadUInt16(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipUInt16() { input.SkipBytes(2); @@ -526,17 +456,13 @@ namespace Bond.Protocols /// Read an UInt32 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public uint ReadUInt32() { return input.ReadUInt32(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipUInt32() { input.SkipBytes(4); @@ -546,17 +472,13 @@ namespace Bond.Protocols /// Read an UInt64 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public UInt64 ReadUInt64() { return input.ReadUInt64(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipUInt64() { input.SkipBytes(8); @@ -566,17 +488,13 @@ namespace Bond.Protocols /// Read an Int8 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public sbyte ReadInt8() { return unchecked((sbyte)input.ReadUInt8()); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipInt8() { input.SkipBytes(1); @@ -586,17 +504,13 @@ namespace Bond.Protocols /// Read an Int16 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public short ReadInt16() { return unchecked((short)input.ReadUInt16()); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipInt16() { input.SkipBytes(2); @@ -606,17 +520,13 @@ namespace Bond.Protocols /// Read an Int32 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public int ReadInt32() { return unchecked((int)input.ReadUInt32()); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipInt32() { input.SkipBytes(4); @@ -626,17 +536,13 @@ namespace Bond.Protocols /// Read an Int64 /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public Int64 ReadInt64() { return unchecked((Int64)input.ReadUInt64()); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipInt64() { input.SkipBytes(8); @@ -646,17 +552,13 @@ namespace Bond.Protocols /// Read an bool /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public bool ReadBool() { return input.ReadUInt8() != 0; } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipBool() { input.SkipBytes(1); @@ -666,17 +568,13 @@ namespace Bond.Protocols /// Read an float /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public float ReadFloat() { return input.ReadFloat(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipFloat() { input.SkipBytes(4); @@ -686,17 +584,13 @@ namespace Bond.Protocols /// Read an double /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public double ReadDouble() { return input.ReadDouble(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipDouble() { input.SkipBytes(8); @@ -706,18 +600,14 @@ namespace Bond.Protocols /// Read a UTF-8 string /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public String ReadString() { var length = ReadLength(); return length == 0 ? string.Empty : input.ReadString(Encoding.UTF8, length); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipString() { input.SkipBytes(ReadLength()); @@ -727,18 +617,14 @@ namespace Bond.Protocols /// Read a UTF-16 string /// /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public string ReadWString() { var length = ReadLength(); return length == 0 ? string.Empty : input.ReadString(Encoding.Unicode, length << 1); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipWString() { input.SkipBytes(ReadLength() << 1); @@ -749,17 +635,13 @@ namespace Bond.Protocols /// /// Number of bytes to read /// -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public ArraySegment ReadBytes(int count) { return input.ReadBytes(count); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void SkipBytes(int count) { input.SkipBytes(count); @@ -767,9 +649,7 @@ namespace Bond.Protocols #endregion -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif int ReadLength() { return (int)((version == 2) ? input.ReadVarUInt32() : input.ReadUInt32()); diff --git a/cs/src/core/protocols/SimpleXmlReader.cs b/cs/src/core/protocols/SimpleXmlReader.cs index c28474e0..80fe32e9 100644 --- a/cs/src/core/protocols/SimpleXmlReader.cs +++ b/cs/src/core/protocols/SimpleXmlReader.cs @@ -48,17 +48,13 @@ namespace Bond.Protocols get { return reader.NamespaceURI; } } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void Read() { reader.Read(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void Skip() { reader.Skip(); diff --git a/cs/src/core/protocols/SimpleXmlWriter.cs b/cs/src/core/protocols/SimpleXmlWriter.cs index f62e0804..f72dc873 100644 --- a/cs/src/core/protocols/SimpleXmlWriter.cs +++ b/cs/src/core/protocols/SimpleXmlWriter.cs @@ -53,59 +53,45 @@ namespace Bond.Protocols #region Struct -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructBegin(Metadata metadata) { writer.WriteStartElement(metadata.GetXmlName()); PushNamespace(metadata); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseBegin(Metadata metadata) { PushNamespace(metadata); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructEnd() { PopNamespace(); writer.WriteEndElement(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseEnd() { PopNamespace(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldBegin(BondDataType dataType, ushort id, Metadata metadata) { writer.WriteStartElement(Prefix, metadata.name, null); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldEnd() { writer.WriteEndElement(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldOmitted(BondDataType dataType, ushort id, Metadata metadata) { } @@ -113,37 +99,27 @@ namespace Bond.Protocols #region Containers -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerBegin(int count, BondDataType elementType) { } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerBegin(int count, BondDataType keyType, BondDataType valueType) { } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteContainerEnd() { } #region ITextProtocolWriter -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteItemBegin() { writer.WriteStartElement("Item"); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteItemEnd() { writer.WriteEndElement(); @@ -155,81 +131,61 @@ namespace Bond.Protocols #region Scalars -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt8(sbyte value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt16(short value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt32(int value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt64(long value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt8(byte value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt16(ushort value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt32(uint value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt64(ulong value) { writer.WriteValue(value.ToString()); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFloat(float value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteDouble(double value) { writer.WriteValue(value); @@ -247,25 +203,19 @@ namespace Bond.Protocols } } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBool(bool value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteString(string value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteWString(string value) { writer.WriteValue(value); diff --git a/cs/src/grpc/grpc.csproj b/cs/src/grpc/grpc.csproj index 35b6a1c3..1110becd 100644 --- a/cs/src/grpc/grpc.csproj +++ b/cs/src/grpc/grpc.csproj @@ -9,7 +9,6 @@ Bond.Grpc Bond.Grpc true - true diff --git a/cs/src/json/JSON.csproj b/cs/src/json/JSON.csproj index c1a52069..309189e0 100644 --- a/cs/src/json/JSON.csproj +++ b/cs/src/json/JSON.csproj @@ -29,9 +29,6 @@ ..\..\packages\Newtonsoft.Json.9.0.1\lib\portable-net45+wp80+win8+wpa81\Newtonsoft.Json.dll - - ..\..\packages\Newtonsoft.Json.9.0.1\lib\portable-net40+sl5+wp80+win8+wpa81\Newtonsoft.Json.dll - diff --git a/cs/src/json/protocols/SimpleJsonReader.cs b/cs/src/json/protocols/SimpleJsonReader.cs index 4aaee833..6c79e54c 100644 --- a/cs/src/json/protocols/SimpleJsonReader.cs +++ b/cs/src/json/protocols/SimpleJsonReader.cs @@ -68,10 +68,8 @@ namespace Bond.Protocols { get { return reader.LinePosition; } } - -#if NET45 + [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void Read() { eof = !reader.Read(); diff --git a/cs/src/json/protocols/SimpleJsonWriter.cs b/cs/src/json/protocols/SimpleJsonWriter.cs index 50d2e5dd..67adadd7 100644 --- a/cs/src/json/protocols/SimpleJsonWriter.cs +++ b/cs/src/json/protocols/SimpleJsonWriter.cs @@ -38,52 +38,38 @@ namespace Bond.Protocols #region Struct -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructBegin(Metadata metadata) { writer.WriteStartObject(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteStructEnd() { writer.WriteEndObject(); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseBegin(Metadata metadata) {} -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBaseEnd() {} -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldBegin(BondDataType type, ushort id, Metadata metadata) { string name; writer.WritePropertyName(metadata.attributes.TryGetValue(NameAttribute, out name) ? name : metadata.name); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldEnd() {} -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFieldOmitted(BondDataType type, ushort id, Metadata metadata) {} @@ -110,9 +96,7 @@ namespace Bond.Protocols #region Scalars -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteBool(bool value) { writer.WriteValue(value); @@ -127,97 +111,73 @@ namespace Bond.Protocols } } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteDouble(double value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteFloat(float value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt16(short value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt32(int value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt64(long value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteInt8(sbyte value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteString(string value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt16(ushort value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt32(uint value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt64(ulong value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteUInt8(byte value) { writer.WriteValue(value); } -#if NET45 [MethodImpl(MethodImplOptions.AggressiveInlining)] -#endif public void WriteWString(string value) { writer.WriteValue(value); diff --git a/cs/src/reflection/Reflection40.cs b/cs/src/reflection/Reflection40.cs deleted file mode 100644 index 105ed968..00000000 --- a/cs/src/reflection/Reflection40.cs +++ /dev/null @@ -1,62 +0,0 @@ -// Copyright (c) Microsoft. All rights reserved. -// Licensed under the MIT license. See LICENSE file in the project root for full license information. - -// Even though this file is compiled conditionally, the #if is necessary to unconfuse resharper -#if NET40 - -namespace Bond.Internal.Reflection -{ - using System; - using System.Collections.Generic; - using System.Reflection; - using System.Linq; - - // Common reflection interface implementation for .NET 4.0 - internal static class Reflection40 - { - const BindingFlags AllDeclared = BindingFlags.NonPublic | BindingFlags.Public | - BindingFlags.Instance | BindingFlags.Static | BindingFlags.DeclaredOnly; - - public static Type GetTypeInfo(this Type type) - { - return type; - } - - public static Type[] GetGenericParameters(this Type type) - { - return type.GetGenericArguments(); - } - - public static IEnumerable GetDeclaredConstructors(this Type type) - { - return type.GetConstructors(AllDeclared); - } - - public static IEnumerable GetDeclaredFields(this Type type) - { - return type.GetFields(AllDeclared); - } - - public static IEnumerable GetDeclaredProperties(this Type type) - { - return type.GetProperties(AllDeclared); - } - - public static PropertyInfo GetDeclaredProperty(this Type type, string name) - { - return type.GetProperty(name, AllDeclared); - } - - public static IEnumerable GetDeclaredMethods(this Type type, string name) - { - return type.GetMethods(AllDeclared).Where(m => m.Name == name); - } - - public static object GetValue(this PropertyInfo property, object o) - { - return property.GetValue(o, null); - } - } -} - -#endif diff --git a/cs/src/reflection/Reflection45.cs b/cs/src/reflection/Reflection45.cs index aa290cba..cd734992 100644 --- a/cs/src/reflection/Reflection45.cs +++ b/cs/src/reflection/Reflection45.cs @@ -1,9 +1,6 @@ // Copyright (c) Microsoft. All rights reserved. // Licensed under the MIT license. See LICENSE file in the project root for full license information. -// Even though this file is compiled conditionally, the #if is necessary to unconfuse resharper -#if !NET40 - namespace Bond.Internal.Reflection { using System; @@ -59,5 +56,3 @@ namespace Bond.Internal.Reflection } } } - -#endif diff --git a/cs/src/reflection/reflection.csproj b/cs/src/reflection/reflection.csproj index cc393d51..81b29bcb 100644 --- a/cs/src/reflection/reflection.csproj +++ b/cs/src/reflection/reflection.csproj @@ -13,7 +13,6 @@ - diff --git a/cs/test/codegen/no-warnings/no-warnings.csproj b/cs/test/codegen/no-warnings/no-warnings.csproj index b1f06eca..55e591b1 100644 --- a/cs/test/codegen/no-warnings/no-warnings.csproj +++ b/cs/test/codegen/no-warnings/no-warnings.csproj @@ -1,7 +1,7 @@  - net40 + net45 diff --git a/cs/test/codegen/output-no-slash/output-no-slash.csproj b/cs/test/codegen/output-no-slash/output-no-slash.csproj index 8ab3e43a..a8b2f51c 100644 --- a/cs/test/codegen/output-no-slash/output-no-slash.csproj +++ b/cs/test/codegen/output-no-slash/output-no-slash.csproj @@ -1,7 +1,7 @@ - net40 + net45 diff --git a/cs/test/comm/comm.csproj b/cs/test/comm/comm.csproj index 5059a691..d81727ba 100644 --- a/cs/test/comm/comm.csproj +++ b/cs/test/comm/comm.csproj @@ -1,7 +1,7 @@ - net40 + net45 @@ -15,7 +15,6 @@ False UnitTest $(OutputPath) - true $(IntermediateOutputPath)\Properties\ @@ -89,9 +88,6 @@ ..\..\packages\Newtonsoft.Json.9.0.1\lib\portable-net45+wp80+win8+wpa81\Newtonsoft.Json.dll - - ..\..\packages\Newtonsoft.Json.9.0.1\lib\portable-net40+sl5+wp80+win8+wpa81\Newtonsoft.Json.dll - diff --git a/cs/test/compat/comm/client/CommCompatClient.csproj b/cs/test/compat/comm/client/CommCompatClient.csproj index 5cd65a91..4aebb7f3 100644 --- a/cs/test/compat/comm/client/CommCompatClient.csproj +++ b/cs/test/compat/comm/client/CommCompatClient.csproj @@ -9,7 +9,6 @@ CommCompatClient CommCompatClient v4.5 - true diff --git a/cs/test/compat/comm/server/CommCompatServer.csproj b/cs/test/compat/comm/server/CommCompatServer.csproj index b7d8e471..8049ed40 100644 --- a/cs/test/compat/comm/server/CommCompatServer.csproj +++ b/cs/test/compat/comm/server/CommCompatServer.csproj @@ -9,7 +9,6 @@ CommCompatServer CommCompatServer v4.5 - true diff --git a/cs/test/compat/comm/shared/CommCompatShared.csproj b/cs/test/compat/comm/shared/CommCompatShared.csproj index ee3e46f8..880e6bf5 100644 --- a/cs/test/compat/comm/shared/CommCompatShared.csproj +++ b/cs/test/compat/comm/shared/CommCompatShared.csproj @@ -9,7 +9,6 @@ CommCompatShared CommCompatShared v4.5 - true diff --git a/cs/test/compat/grpc/client/GrpcCompatClient.csproj b/cs/test/compat/grpc/client/GrpcCompatClient.csproj index 878d0190..51796fea 100644 --- a/cs/test/compat/grpc/client/GrpcCompatClient.csproj +++ b/cs/test/compat/grpc/client/GrpcCompatClient.csproj @@ -9,7 +9,6 @@ GrpcCompatClient GrpcCompatClient v4.5 - true diff --git a/cs/test/compat/grpc/server/GrpcCompatServer.csproj b/cs/test/compat/grpc/server/GrpcCompatServer.csproj index f52ce415..542dbe58 100644 --- a/cs/test/compat/grpc/server/GrpcCompatServer.csproj +++ b/cs/test/compat/grpc/server/GrpcCompatServer.csproj @@ -9,7 +9,6 @@ GrpcCompatServer GrpcCompatServer v4.5 - true diff --git a/cs/test/compat/grpc/shared/GrpcCompatShared.csproj b/cs/test/compat/grpc/shared/GrpcCompatShared.csproj index e14689a8..cd0d2492 100644 --- a/cs/test/compat/grpc/shared/GrpcCompatShared.csproj +++ b/cs/test/compat/grpc/shared/GrpcCompatShared.csproj @@ -9,7 +9,6 @@ GrpcCompatShared GrpcCompatShared v4.5 - true diff --git a/cs/test/core/Core.csproj b/cs/test/core/Core.csproj index 10df079d..b2551fe4 100644 --- a/cs/test/core/Core.csproj +++ b/cs/test/core/Core.csproj @@ -1,7 +1,7 @@  - net40 + net45 @@ -20,7 +20,7 @@ $(IntermediateOutputPath)\Properties\ $(OutputPath)\Properties\ - + $(IntermediateOutputPath)\Fields\ @@ -56,8 +56,7 @@ - $(BondOptions) --using="Lazy=Lazy<{0}>" --using="OrderedSet=SortedSet<{0}>" --using="Decimal=decimal" --using="EnumString=Alias.EnumString<{0}>" --using="Array={0}[]" --using=ArrayBlob=byte[] --using="CustomList=UnitTest.Aliases.SomeCustomList<{0}>" - $(BondOptions) --using="Lazy=Lazy<{0}>" --using="OrderedSet=SortedSet<{0}>" --using="Decimal=decimal" --using="EnumString=Alias.EnumString<{0}>" --using="Array={0}[]" --using=ArrayBlob=byte[] --using="CustomList=UnitTest.Aliases.SomeCustomList<{0}>" + $(BondOptions) --using="Lazy=Lazy<{0}>" --using="OrderedSet=SortedSet<{0}>" --using="Decimal=decimal" --using="EnumString=Alias.EnumString<{0}>" --using="Array={0}[]" --using=ArrayBlob=byte[] --using="CustomList=UnitTest.Aliases.SomeCustomList<{0}>" @@ -93,9 +92,6 @@ ..\..\packages\Newtonsoft.Json.9.0.1\lib\portable-net45+wp80+win8+wpa81\Newtonsoft.Json.dll - - ..\..\packages\Newtonsoft.Json.9.0.1\lib\portable-net40+sl5+wp80+win8+wpa81\Newtonsoft.Json.dll - diff --git a/cs/test/grpc/grpc.csproj b/cs/test/grpc/grpc.csproj index ed3b2fb9..181090e7 100644 --- a/cs/test/grpc/grpc.csproj +++ b/cs/test/grpc/grpc.csproj @@ -12,7 +12,6 @@ False UnitTest $(OutputPath) - true $(IntermediateOutputPath)\Properties\ diff --git a/doc/src/bond_cs.md b/doc/src/bond_cs.md index f23c14ad..6c82f0d6 100644 --- a/doc/src/bond_cs.md +++ b/doc/src/bond_cs.md @@ -847,8 +847,6 @@ how to achieve the best performance. amortized. The canonical use case for an untagged protocol is record-based data storage. -6. Using .NET 4.5 will give better performance than 4.0. - Runtime schema ============== @@ -1528,16 +1526,16 @@ namespace). This table lists which frameworks are targeted by the Bond assemblies. -This table is accurate for Bond NuGet packages 5.1.0 and later and Bond Comm -0.9.0 and later. +This table is accurate for Bond NuGet packages 6.0.0 and later and Bond Comm +0.12.0 and later. | Assembly | .NET 4.0 | .NET 4.5 | Profile78 | .NET Standard 1.0 | .NET Standard 1.3 | .NET Standard 1.6 | |--------------------------|----------|----------|-----------|-------------------|-------------------|-------------------| -| Bond.Attributes.dll | Yes | Yes | Yes | Yes | ← | Yes | -| Bond.Reflection.dll | Yes | Yes | Yes | Yes | ← | Yes | -| Bond.dll | Yes | Yes | Yes | Yes | ← | Yes | -| Bond.JSON.dll | Yes | Yes | No | Yes | ← | Yes | -| Bond.IO.dll | Win only | Win only | No | No | Win only | Win only | +| Bond.Attributes.dll | No | Yes | Yes | Yes | ← | Yes | +| Bond.Reflection.dll | No | Yes | Yes | Yes | ← | Yes | +| Bond.dll | No | Yes | Yes | Yes | ← | Yes | +| Bond.JSON.dll | No | Yes | No | Yes | ← | Yes | +| Bond.IO.dll | No | Win only | No | No | Win only | Win only | | Bond.Comm.Interfaces.dll | No | Yes | Yes | ← | ← | ← | | Bond.Comm.Layers.dll | No | Yes | Yes | ← | ← | ← | | Bond.Comm.Services.dll | No | Yes | Yes | ← | ← | ← |