diff options
Diffstat (limited to 'src/mscorlib/src/System/BitConverter.cs')
-rw-r--r-- | src/mscorlib/src/System/BitConverter.cs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mscorlib/src/System/BitConverter.cs b/src/mscorlib/src/System/BitConverter.cs index 3a6d1c03b0..07af5a8178 100644 --- a/src/mscorlib/src/System/BitConverter.cs +++ b/src/mscorlib/src/System/BitConverter.cs @@ -63,7 +63,7 @@ namespace System { Contract.Ensures(Contract.Result<byte[]>().Length == 2); byte[] bytes = new byte[2]; - fixed(byte* b = bytes) + fixed(byte* b = &bytes[0]) *((short*)b) = value; return bytes; } @@ -76,7 +76,7 @@ namespace System { Contract.Ensures(Contract.Result<byte[]>().Length == 4); byte[] bytes = new byte[4]; - fixed(byte* b = bytes) + fixed(byte* b = &bytes[0]) *((int*)b) = value; return bytes; } @@ -89,7 +89,7 @@ namespace System { Contract.Ensures(Contract.Result<byte[]>().Length == 8); byte[] bytes = new byte[8]; - fixed(byte* b = bytes) + fixed(byte* b = &bytes[0]) *((long*)b) = value; return bytes; } |