Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.

Commit 9f68fd9

Browse files
jkotasdotnet-bot
authored andcommitted
Move SafeBuffer and a few other files to shared CoreLib partition (#15141)
Signed-off-by: dotnet-bot-corefx-mirror <[email protected]>
1 parent a5dbd38 commit 9f68fd9

File tree

6 files changed

+964
-1
lines changed

6 files changed

+964
-1
lines changed

src/Common/src/CoreLib/System.Private.CoreLib.Shared.projitems

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -400,6 +400,7 @@
400400
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\ConstrainedExecution\Cer.cs" />
401401
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\ConstrainedExecution\Consistency.cs" />
402402
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\ConstrainedExecution\ReliabilityContractAttribute.cs" />
403+
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\ExceptionServices\ExceptionNotification.cs" />
403404
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\ExceptionServices\HandleProcessCorruptedStateExceptionsAttribute.cs" />
404405
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\BestFitMappingAttribute.cs" />
405406
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\CallingConvention.cs" />
@@ -414,10 +415,12 @@
414415
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\InAttribute.cs" />
415416
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\LayoutKind.cs" />
416417
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\MarshalAsAttribute.cs" />
418+
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\MarshalDirectiveException.cs" />
417419
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\MemoryMarshal.cs" />
418420
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\OptionalAttribute.cs" />
419421
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\OutAttribute.cs" />
420422
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\PreserveSigAttribute.cs" />
423+
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\SafeBuffer.cs" />
421424
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\StringBuffer.cs" />
422425
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\StructLayoutAttribute.cs" />
423426
<Compile Include="$(MSBuildThisFileDirectory)System\Runtime\InteropServices\UnmanagedFunctionPointerAttribute.cs" />
@@ -512,6 +515,7 @@
512515
<Compile Include="$(MSBuildThisFileDirectory)System\Threading\SpinWait.cs" />
513516
<Compile Include="$(MSBuildThisFileDirectory)System\Threading\SynchronizationLockException.cs" />
514517
<Compile Include="$(MSBuildThisFileDirectory)System\Threading\Tasks\TaskCanceledException.cs" />
518+
<Compile Include="$(MSBuildThisFileDirectory)System\Threading\Tasks\TaskCompletionSource.cs" />
515519
<Compile Include="$(MSBuildThisFileDirectory)System\Threading\Tasks\TaskExtensions.cs" />
516520
<Compile Include="$(MSBuildThisFileDirectory)System\Threading\Tasks\TaskToApm.cs" />
517521
<Compile Include="$(MSBuildThisFileDirectory)System\Threading\Tasks\TaskSchedulerException.cs" />
@@ -704,13 +708,14 @@
704708
<Compile Include="$(MSBuildThisFileDirectory)System\Globalization\CultureData.Unix.cs" Condition="'$(EnableDummyGlobalizationImplementation)' != 'true'" />
705709
<Compile Include="$(MSBuildThisFileDirectory)System\Globalization\HijriCalendar.Unix.cs" Condition="'$(EnableDummyGlobalizationImplementation)' != 'true'" />
706710
<Compile Include="$(MSBuildThisFileDirectory)System\Globalization\IdnMapping.Unix.cs" Condition="'$(EnableDummyGlobalizationImplementation)' != 'true'" />
707-
<Compile Include="$(MSBuildThisFileDirectory)System\Globalization\LocaleData.Unix.cs" Condition="'$(EnableDummyGlobalizationImplementation)' != 'true'" />
708711
<Compile Include="$(MSBuildThisFileDirectory)System\Globalization\JapaneseCalendar.Unix.cs" Condition="'$(EnableDummyGlobalizationImplementation)' != 'true'" />
712+
<Compile Include="$(MSBuildThisFileDirectory)System\Globalization\LocaleData.Unix.cs" Condition="'$(EnableDummyGlobalizationImplementation)' != 'true'" />
709713
<Compile Include="$(MSBuildThisFileDirectory)System\IO\FileStream.OSX.cs" Condition="'$(TargetsOSX)' == 'true'" />
710714
<Compile Include="$(MSBuildThisFileDirectory)System\IO\FileStream.Linux.cs" Condition="'$(TargetsOSX)' != 'true'" />
711715
<Compile Include="$(MSBuildThisFileDirectory)System\IO\FileStream.Unix.cs" />
712716
<Compile Include="$(MSBuildThisFileDirectory)System\IO\Path.Unix.cs" />
713717
<Compile Include="$(MSBuildThisFileDirectory)System\IO\PathInternal.Unix.cs" />
714718
<Compile Include="$(MSBuildThisFileDirectory)System\Security\SecureString.Unix.cs" />
719+
<Compile Include="$(MSBuildThisFileDirectory)System\Text\Normalization.Unix.cs" Condition="'$(EnableDummyGlobalizationImplementation)' != 'true'" />
715720
</ItemGroup>
716721
</Project>
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
// Licensed to the .NET Foundation under one or more agreements.
2+
// The .NET Foundation licenses this file to you under the MIT license.
3+
// See the LICENSE file in the project root for more information.
4+
5+
namespace System.Runtime.ExceptionServices
6+
{
7+
// Definition of the argument-type passed to the FirstChanceException event handler
8+
public class FirstChanceExceptionEventArgs : EventArgs
9+
{
10+
public FirstChanceExceptionEventArgs(Exception exception)
11+
{
12+
Exception = exception;
13+
}
14+
15+
// Returns the exception object pertaining to the first chance exception
16+
public Exception Exception { get; }
17+
}
18+
}
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
// Licensed to the .NET Foundation under one or more agreements.
2+
// The .NET Foundation licenses this file to you under the MIT license.
3+
// See the LICENSE file in the project root for more information.
4+
5+
/*=============================================================================
6+
**
7+
**
8+
** Purpose: This exception is thrown when the marshaller encounters a signature
9+
** that has an invalid MarshalAs CA for a given argument or is not
10+
** supported.
11+
**
12+
=============================================================================*/
13+
14+
15+
using System;
16+
using System.Runtime.Serialization;
17+
18+
namespace System.Runtime.InteropServices
19+
{
20+
[Serializable]
21+
[System.Runtime.CompilerServices.TypeForwardedFrom("mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089")]
22+
public class MarshalDirectiveException : SystemException
23+
{
24+
public MarshalDirectiveException()
25+
: base(SR.Arg_MarshalDirectiveException)
26+
{
27+
HResult = HResults.COR_E_MARSHALDIRECTIVE;
28+
}
29+
30+
public MarshalDirectiveException(String message)
31+
: base(message)
32+
{
33+
HResult = HResults.COR_E_MARSHALDIRECTIVE;
34+
}
35+
36+
public MarshalDirectiveException(String message, Exception inner)
37+
: base(message, inner)
38+
{
39+
HResult = HResults.COR_E_MARSHALDIRECTIVE;
40+
}
41+
42+
protected MarshalDirectiveException(SerializationInfo info, StreamingContext context) : base(info, context)
43+
{
44+
}
45+
}
46+
}

0 commit comments

Comments
 (0)