-
Notifications
You must be signed in to change notification settings - Fork 5k
Remove the System.Runtime.InteropServices.PInvoke contract #8626
Conversation
….PInvoke contract
@yizhang82 @tijoytom @weshaggard @ericstj Please take a look. |
I don't think we can lower version numbers at this point since the RC2 packages are public and supported, can we? |
System.Runtime already has other additions that establish 4.1.0.0, just have a look at https://github.com/dotnet/corefx/commits/master/src/System.Runtime/ref/System.Runtime.cs. InteropServices needs to stay at 4.1.0.0 as well for the UTF8 change you mention. The only thing this change should do is delete IS.Pinvoke, delete dependencies on it, and remove the explicit type forwards from IS. You may also need to fix up https://github.com/dotnet/corefx/blob/ca5d1174dbaa12b8b6e55dc494fcd4609ed553cc/src/System.Runtime.CompilerServices.Unsafe/tests/UnsafeTests.cs. |
// See the LICENSE file in the project root for more information. | ||
|
||
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.InteropServices.GCHandle))] | ||
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Runtime.InteropServices.GCHandleType))] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ericstj This change also removes explicit type forwards of GCHandle from System.Runtime. Should I leave this change in here?
…InteropServices as part of the removal of S.R.IS.PInvoke. Also, remove a reference to PInvokeMarshal in the Unsafe tests.
cc: @raja-krishnan, @terrajobst |
It's irrelevant since InteropServices already is part of netstandard and thus must be supported everywhere. Removing it from netstandard means breaking changes (marshal) which are against the direction we are heading for API convergence. What benefit do you see in keeping it? |
LGTM. There are merge conflicts that need to be fixed before this is merged. |
…refx#8626) Revert the changes that introduced the System.Runtime.InteropServices.PInvoke contract Don't bump down version numbers of System.Runtime and System.Runtime.InteropServices as part of the removal of S.R.IS.PInvoke. Also, remove a reference to PInvokeMarshal in the Unsafe tests. Commit migrated from dotnet/corefx@1b61b69
Per issue #7754, removing the System.Runtime.InteropServices.PInvoke contract.
This contract was introduced several months ago, but is no longer aligned with our direction for .NET Core APIs.
I bumped the version numbers of System.Runtime.InteropServices and System.Runtime back down from 4.1.0.0 to 4.0.21.0. If we need to, we can keep the 4.1.0.0 version around for the new UTF8 changes (#8607). I am wondering what extra we need to do for System.Runtime though, if we want to bump the version numbers down again.