Update BitConverter from CoreFX#9788
Conversation
Related to #9701
|
Would it make sense to copy the initialization of |
|
I kept it because of there are number of BIGENDIAN ifdefs in corelib today, and so this is following the corelib style for endianness specific code. |
|
Wait for the current CoreCLR drop to stabilize in corefx before pushing this through (see dotnet/corefx#16454) |
|
@stephentoub I see you have commented on the other PR related to this. Could you please take a look? |
|
|
||
| internal static string ArgumentOutOfRange_GenericPositive | ||
| { | ||
| get { return Environment.GetResourceString("ArgumentOutOfRange_GenericPositive"); } |
There was a problem hiding this comment.
Nit: Not for this PR, but at some point subsequently we might want to go through and replace all of this strings with nameof, e.g.
using static Environment;
...
internal static string ArgumentOutOfRange_GenericPositive => GetResourceString(nameof(ArgumentOutOfRange_GenericPositive);There was a problem hiding this comment.
The plan is switch this file to be auto-generated like everywhere else(https://github.com/dotnet/coreclr/issues/9474)
|
|
||
| private static void ThrowValueArgumentNull() | ||
| { | ||
| throw new ArgumentNullException("value"); |
There was a problem hiding this comment.
Did you purposefully decide against ThrowHelper for these exceptions?
There was a problem hiding this comment.
Not really ... just copied what was in corefx. I have fixed it up to use ThrowHelper.
|
@dotnet-bot test Linux ARM Emulator Cross Release Build |
* Update BitConverter from CoreFX Related to #9701 * Use ThrowHelper
* Update BitConverter from CoreFX Related to dotnet/coreclr#9701 * Use ThrowHelper Commit migrated from dotnet/coreclr@a5e0190
Related to #9701