Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/corert.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJan Kotas <jkotas@microsoft.com>2018-03-06 06:32:00 +0300
committerJan Kotas <jkotas@microsoft.com>2018-03-06 09:29:21 +0300
commit4b9c387857d9dbc9f1fe0bdb046b57c3a4499be6 (patch)
tree0bfcb4f09da47472fdb425b0ba73b80c11ca65f3 /src
parent68679f4350785a333c33a9a9f21bf4911ed49d22 (diff)
Port changes in non-shared CoreLib partition
Diffstat (limited to 'src')
-rw-r--r--src/Common/src/Interop/Windows/mincore/Interop.CoCreateGuid.cs15
-rw-r--r--src/System.Private.CoreLib/src/System.Private.CoreLib.csproj5
-rw-r--r--src/System.Private.CoreLib/src/System/Guid.Unix.cs24
-rw-r--r--src/System.Private.CoreLib/src/System/Guid.Windows.cs31
4 files changed, 0 insertions, 75 deletions
diff --git a/src/Common/src/Interop/Windows/mincore/Interop.CoCreateGuid.cs b/src/Common/src/Interop/Windows/mincore/Interop.CoCreateGuid.cs
deleted file mode 100644
index ac3bad582..000000000
--- a/src/Common/src/Interop/Windows/mincore/Interop.CoCreateGuid.cs
+++ /dev/null
@@ -1,15 +0,0 @@
-// Licensed to the .NET Foundation under one or more agreements.
-// The .NET Foundation licenses this file to you under the MIT license.
-// See the LICENSE file in the project root for more information.
-
-using System;
-using System.Runtime.InteropServices;
-
-internal static partial class Interop
-{
- internal static partial class mincore
- {
- [DllImport("api-ms-win-core-com-l1-1-0.dll")]
- internal extern static int CoCreateGuid(out Guid pguid);
- }
-}
diff --git a/src/System.Private.CoreLib/src/System.Private.CoreLib.csproj b/src/System.Private.CoreLib/src/System.Private.CoreLib.csproj
index 9f041c462..58f19377e 100644
--- a/src/System.Private.CoreLib/src/System.Private.CoreLib.csproj
+++ b/src/System.Private.CoreLib/src/System.Private.CoreLib.csproj
@@ -223,8 +223,6 @@
<Compile Include="System\Environment.cs" />
<Compile Include="System\GC.cs" />
<Compile Include="System\Globalization\CultureInfo.cs" />
- <Compile Include="System\Guid.Windows.cs" Condition="'$(TargetsWindows)'=='true'" />
- <Compile Include="System\Guid.Unix.cs" Condition="'$(TargetsUnix)'=='true'" />
<Compile Include="System\Helpers.cs" />
<Compile Include="System\InsufficientMemoryException.cs" />
<Compile Include="System\Marvin.cs" />
@@ -530,9 +528,6 @@
<Compile Condition="'$(EnableWinRT)' != 'true'" Include="..\..\Common\src\Interop\Windows\mincore\Interop.GetSystemDirectory.cs">
<Link>Interop\Windows\mincore\Interop.GetSystemDirectory.cs</Link>
</Compile>
- <Compile Include="..\..\Common\src\Interop\Windows\mincore\Interop.CoCreateGuid.cs">
- <Link>Interop\Windows\mincore\Interop.CoCreateGuid.cs</Link>
- </Compile>
<Compile Include="..\..\Common\src\Interop\Windows\mincore\Interop.QueryUnbiasedInterruptTime.cs">
<Link>Interop\Windows\mincore\Interop.QueryUnbiasedInterruptTime.cs</Link>
</Compile>
diff --git a/src/System.Private.CoreLib/src/System/Guid.Unix.cs b/src/System.Private.CoreLib/src/System/Guid.Unix.cs
deleted file mode 100644
index 326362d04..000000000
--- a/src/System.Private.CoreLib/src/System/Guid.Unix.cs
+++ /dev/null
@@ -1,24 +0,0 @@
-// Licensed to the .NET Foundation under one or more agreements.
-// The .NET Foundation licenses this file to you under the MIT license.
-// See the LICENSE file in the project root for more information.
-
-using System.Diagnostics;
-using System.Runtime.InteropServices;
-
-namespace System
-{
- partial struct Guid
- {
- // This will create a new guid. Since we've now decided that constructors should 0-init,
- // we need a method that allows users to create a guid.
- public static Guid NewGuid()
- {
- // CoCreateGuid should never return Guid.Empty, since it attempts to maintain some
- // uniqueness guarantees. It should also never return a known GUID, but it's unclear
- // how extensively it checks for known values.
-
- Interop.Sys.CreateGuid(out Guid g);
- return g;
- }
- }
-}
diff --git a/src/System.Private.CoreLib/src/System/Guid.Windows.cs b/src/System.Private.CoreLib/src/System/Guid.Windows.cs
deleted file mode 100644
index f21dfbd6b..000000000
--- a/src/System.Private.CoreLib/src/System/Guid.Windows.cs
+++ /dev/null
@@ -1,31 +0,0 @@
-// Licensed to the .NET Foundation under one or more agreements.
-// The .NET Foundation licenses this file to you under the MIT license.
-// See the LICENSE file in the project root for more information.
-
-namespace System
-{
- partial struct Guid
- {
- // This will create a new guid. Since we've now decided that constructors should 0-init,
- // we need a method that allows users to create a guid.
- public static Guid NewGuid()
- {
- // CoCreateGuid should never return Guid.Empty, since it attempts to maintain some
- // uniqueness guarantees. It should also never return a known GUID, but it's unclear
- // how extensively it checks for known values.
-
- Guid g;
- int hr = Interop.mincore.CoCreateGuid(out g);
- // We don't expect that this will ever throw an error, none are even documented, and so we don't want to pull
- // in the HR to ComException mappings into the core library just for this so we will try a generic exception if
- // we ever hit this condition.
- if (hr != 0)
- {
- Exception ex = new Exception();
- ex.SetErrorCode(hr);
- throw ex;
- }
- return g;
- }
- }
-}