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
diff options
context:
space:
mode:
authorMorgan Brown <morganbr@users.noreply.github.com>2017-05-24 03:11:24 +0300
committerJan Kotas <jkotas@microsoft.com>2017-05-24 04:16:08 +0300
commitbc786755626a5e8b90bc8a1ff9a7cd2e0a4e44fc (patch)
tree875d0ec6eae1d6b5596951b872bf8600c9122e8d
parentfe602eda2c5bc93dd2910d785bbf34b5f36903fb (diff)
Scale back [Serializable] on CoreCLR types (dotnet/coreclr#11765)
Removes SerializableAttribute from CoreCLR types not intended to be serializable as well as adding special handling to MulticastDelegate to prevent serializing delegates (which can't be correctly serialized cross platform/runtime). Signed-off-by: dotnet-bot <dotnet-bot@microsoft.com>
-rw-r--r--src/System.Private.CoreLib/shared/System/ApplicationException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/ArgumentException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/ArgumentNullException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/ArgumentOutOfRangeException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/ArithmeticException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/ArrayTypeMismatchException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/AttributeUsageAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/BadImageFormatException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/CLSCompliantAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/CharEnumerator.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Collections/Generic/KeyNotFoundException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/CurrentSystemTimeZone.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/DBNull.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/DataMisalignedException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/DefaultBinder.cs2
-rw-r--r--src/System.Private.CoreLib/shared/System/Diagnostics/ConditionalAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Diagnostics/Tracing/EventSourceException.cs4
-rw-r--r--src/System.Private.CoreLib/shared/System/DivideByZeroException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/DllNotFoundException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/DuplicateWaitObjectException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/EntryPointNotFoundException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/EventArgs.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/ExecutionEngineException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/FieldAccessException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/FlagsAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/FormatException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/ChineseLunisolarCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/CultureNotFoundException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/DateTimeFormatInfo.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/DaylightTime.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/EastAsianLunisolarCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/HebrewCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/HijriCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/JapaneseCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/JapaneseLunisolarCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/JulianCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/KoreanCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/KoreanLunisolarCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/NumberFormatInfo.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/PersianCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/SortKey.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/StringInfo.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/TaiwanCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/TaiwanLunisolarCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/ThaiBuddhistCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Globalization/UmAlQuraCalendar.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/IO/DirectoryNotFoundException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/IO/EndOfStreamException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/IO/FileLoadException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/IO/FileNotFoundException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/IO/PathTooLongException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/IndexOutOfRangeException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/InsufficientExecutionStackException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/InvalidCastException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/InvalidOperationException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/InvalidProgramException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/InvalidTimeZoneException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/MarshalByRefObject.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/MemberAccessException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/MethodAccessException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/MissingMethodException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/MulticastNotSupportedException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/NotFiniteNumberException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/NotImplementedException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/NotSupportedException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/NullReferenceException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/ObjectDisposedException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/ObsoleteAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/OperationCanceledException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/OverflowException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/PlatformNotSupportedException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Random.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/RankException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/AmbiguousMatchException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/CustomAttributeFormatException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/DefaultMemberAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/InvalidFilterCriteriaException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/MemberInfoSerializationHolder.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/Missing.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/ParameterModifier.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/Pointer.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/ReflectionTypeLoadException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/StrongNameKeyPair.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/TargetException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/TargetInvocationException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/TargetParameterCountException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Reflection/TypeDelegator.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Resources/MissingManifestResourceException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Resources/MissingSatelliteAssemblyException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/AsyncStateMachineAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilationRelaxationsAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilerGeneratedAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilerGlobalScopeAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/DefaultDependencyAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/DependencyAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/FixedAddressValueTypeAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IndexerNameAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IteratorStateMachineAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/ReferenceAssemblyAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/RuntimeCompatibilityAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/StateMachineAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/StringFreezingAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/UnsafeValueTypeAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/InteropServices/ExternalException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/Serialization/SerializationException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Runtime/Serialization/StreamingContext.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Security/CryptographicException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Security/SecurityException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Security/VerificationException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/StackOverflowException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/SystemException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Text/ASCIIEncoding.cs2
-rw-r--r--src/System.Private.CoreLib/shared/System/Text/Decoder.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Text/Encoder.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Text/EncodingInfo.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Text/EncodingNLS.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Text/UTF32Encoding.cs2
-rw-r--r--src/System.Private.CoreLib/shared/System/Text/UTF8Encoding.cs4
-rw-r--r--src/System.Private.CoreLib/shared/System/Text/UnicodeEncoding.cs2
-rw-r--r--src/System.Private.CoreLib/shared/System/ThreadStaticAttribute.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/AbandonedMutexException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/ExecutionContext.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/LockRecursionException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/SemaphoreFullException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/SynchronizationLockException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/Tasks/TaskCanceledException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/Tasks/TaskSchedulerException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/ThreadAbortException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/ThreadStartException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/ThreadStateException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Threading/WaitHandleCannotBeOpenedException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/TimeZoneNotFoundException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/TimeoutException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/TypeAccessException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/TypeInitializationException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/TypeUnloadedException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/UnauthorizedAccessException.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/UnhandledExceptionEventArgs.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/UnitySerializationHolder.cs1
-rw-r--r--src/System.Private.CoreLib/shared/System/Void.cs1
140 files changed, 2 insertions, 148 deletions
diff --git a/src/System.Private.CoreLib/shared/System/ApplicationException.cs b/src/System.Private.CoreLib/shared/System/ApplicationException.cs
index 900feb57f..89c665c26 100644
--- a/src/System.Private.CoreLib/shared/System/ApplicationException.cs
+++ b/src/System.Private.CoreLib/shared/System/ApplicationException.cs
@@ -23,7 +23,6 @@ namespace System
// ApplicationException extends but adds no new functionality to
// RecoverableException.
//
- [Serializable]
public class ApplicationException : Exception
{
// Creates a new ApplicationException with its message string set to
diff --git a/src/System.Private.CoreLib/shared/System/ArgumentException.cs b/src/System.Private.CoreLib/shared/System/ArgumentException.cs
index 96afbe10d..ce045f1fd 100644
--- a/src/System.Private.CoreLib/shared/System/ArgumentException.cs
+++ b/src/System.Private.CoreLib/shared/System/ArgumentException.cs
@@ -20,7 +20,6 @@ namespace System
// the contract of the method. Ideally it should give a meaningful error
// message describing what was wrong and which parameter is incorrect.
//
- [Serializable]
public class ArgumentException : SystemException
{
private String _paramName;
diff --git a/src/System.Private.CoreLib/shared/System/ArgumentNullException.cs b/src/System.Private.CoreLib/shared/System/ArgumentNullException.cs
index 3a86223cc..343cadc69 100644
--- a/src/System.Private.CoreLib/shared/System/ArgumentNullException.cs
+++ b/src/System.Private.CoreLib/shared/System/ArgumentNullException.cs
@@ -18,7 +18,6 @@ namespace System
// The ArgumentException is thrown when an argument
// is null when it shouldn't be.
//
- [Serializable]
public class ArgumentNullException : ArgumentException
{
// Creates a new ArgumentNullException with its message
diff --git a/src/System.Private.CoreLib/shared/System/ArgumentOutOfRangeException.cs b/src/System.Private.CoreLib/shared/System/ArgumentOutOfRangeException.cs
index eeeadcbfa..08592aa29 100644
--- a/src/System.Private.CoreLib/shared/System/ArgumentOutOfRangeException.cs
+++ b/src/System.Private.CoreLib/shared/System/ArgumentOutOfRangeException.cs
@@ -18,7 +18,6 @@ namespace System
{
// The ArgumentOutOfRangeException is thrown when an argument
// is outside the legal range for that argument.
- [Serializable]
public class ArgumentOutOfRangeException : ArgumentException
{
private Object _actualValue;
diff --git a/src/System.Private.CoreLib/shared/System/ArithmeticException.cs b/src/System.Private.CoreLib/shared/System/ArithmeticException.cs
index 081ba454f..cd7796525 100644
--- a/src/System.Private.CoreLib/shared/System/ArithmeticException.cs
+++ b/src/System.Private.CoreLib/shared/System/ArithmeticException.cs
@@ -18,7 +18,6 @@ namespace System
// The ArithmeticException is thrown when overflow or underflow
// occurs.
//
- [Serializable]
public class ArithmeticException : SystemException
{
// Creates a new ArithmeticException with its message string set to
diff --git a/src/System.Private.CoreLib/shared/System/ArrayTypeMismatchException.cs b/src/System.Private.CoreLib/shared/System/ArrayTypeMismatchException.cs
index 3e941fdf8..b6ce5fa4a 100644
--- a/src/System.Private.CoreLib/shared/System/ArrayTypeMismatchException.cs
+++ b/src/System.Private.CoreLib/shared/System/ArrayTypeMismatchException.cs
@@ -18,7 +18,6 @@ namespace System
// The ArrayMismatchException is thrown when an attempt to store
// an object of the wrong type within an array occurs.
//
- [Serializable]
public class ArrayTypeMismatchException : SystemException
{
// Creates a new ArrayMismatchException with its message string set to
diff --git a/src/System.Private.CoreLib/shared/System/AttributeUsageAttribute.cs b/src/System.Private.CoreLib/shared/System/AttributeUsageAttribute.cs
index 6f9aeb20f..219dc43e1 100644
--- a/src/System.Private.CoreLib/shared/System/AttributeUsageAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/AttributeUsageAttribute.cs
@@ -16,7 +16,6 @@ using System.Reflection;
namespace System
{
/* By default, attributes are inherited and multiple attributes are not allowed */
- [Serializable]
[AttributeUsage(AttributeTargets.Class, Inherited = true)]
public sealed class AttributeUsageAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/BadImageFormatException.cs b/src/System.Private.CoreLib/shared/System/BadImageFormatException.cs
index 150330b58..2ceaa8b6c 100644
--- a/src/System.Private.CoreLib/shared/System/BadImageFormatException.cs
+++ b/src/System.Private.CoreLib/shared/System/BadImageFormatException.cs
@@ -17,7 +17,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public partial class BadImageFormatException : SystemException
{
private String _fileName; // The name of the corrupt PE file.
diff --git a/src/System.Private.CoreLib/shared/System/CLSCompliantAttribute.cs b/src/System.Private.CoreLib/shared/System/CLSCompliantAttribute.cs
index e03600d13..d895b5ac7 100644
--- a/src/System.Private.CoreLib/shared/System/CLSCompliantAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/CLSCompliantAttribute.cs
@@ -13,7 +13,6 @@
namespace System
{
- [Serializable]
[AttributeUsage(AttributeTargets.All, Inherited = true, AllowMultiple = false)]
public sealed class CLSCompliantAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/CharEnumerator.cs b/src/System.Private.CoreLib/shared/System/CharEnumerator.cs
index 4dbd5cd58..ea9915a7c 100644
--- a/src/System.Private.CoreLib/shared/System/CharEnumerator.cs
+++ b/src/System.Private.CoreLib/shared/System/CharEnumerator.cs
@@ -17,7 +17,6 @@ using System.Collections.Generic;
namespace System
{
- [Serializable]
public sealed class CharEnumerator : IEnumerator, IEnumerator<char>, IDisposable, ICloneable
{
private String _str;
diff --git a/src/System.Private.CoreLib/shared/System/Collections/Generic/KeyNotFoundException.cs b/src/System.Private.CoreLib/shared/System/Collections/Generic/KeyNotFoundException.cs
index 1fca7732a..fa4de8314 100644
--- a/src/System.Private.CoreLib/shared/System/Collections/Generic/KeyNotFoundException.cs
+++ b/src/System.Private.CoreLib/shared/System/Collections/Generic/KeyNotFoundException.cs
@@ -7,7 +7,6 @@ using System.Runtime.Serialization;
namespace System.Collections.Generic
{
- [Serializable]
public class KeyNotFoundException : SystemException
{
public KeyNotFoundException()
diff --git a/src/System.Private.CoreLib/shared/System/CurrentSystemTimeZone.cs b/src/System.Private.CoreLib/shared/System/CurrentSystemTimeZone.cs
index 2d848397a..3f17d6f37 100644
--- a/src/System.Private.CoreLib/shared/System/CurrentSystemTimeZone.cs
+++ b/src/System.Private.CoreLib/shared/System/CurrentSystemTimeZone.cs
@@ -28,7 +28,6 @@ using System.Runtime.Versioning;
namespace System
{
[Obsolete("System.CurrentSystemTimeZone has been deprecated. Please investigate the use of System.TimeZoneInfo.Local instead.")]
- [Serializable]
internal partial class CurrentSystemTimeZone : TimeZone
{
// Standard offset in ticks to the Universal time if
diff --git a/src/System.Private.CoreLib/shared/System/DBNull.cs b/src/System.Private.CoreLib/shared/System/DBNull.cs
index 486eb72f2..507cccb84 100644
--- a/src/System.Private.CoreLib/shared/System/DBNull.cs
+++ b/src/System.Private.CoreLib/shared/System/DBNull.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public sealed class DBNull : ISerializable, IConvertible
{
private DBNull()
diff --git a/src/System.Private.CoreLib/shared/System/DataMisalignedException.cs b/src/System.Private.CoreLib/shared/System/DataMisalignedException.cs
index b1991a048..9c02fc279 100644
--- a/src/System.Private.CoreLib/shared/System/DataMisalignedException.cs
+++ b/src/System.Private.CoreLib/shared/System/DataMisalignedException.cs
@@ -13,7 +13,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public sealed class DataMisalignedException : SystemException
{
public DataMisalignedException()
diff --git a/src/System.Private.CoreLib/shared/System/DefaultBinder.cs b/src/System.Private.CoreLib/shared/System/DefaultBinder.cs
index 3b46d5f4d..9adf702a0 100644
--- a/src/System.Private.CoreLib/shared/System/DefaultBinder.cs
+++ b/src/System.Private.CoreLib/shared/System/DefaultBinder.cs
@@ -8,8 +8,6 @@ using CultureInfo = System.Globalization.CultureInfo;
namespace System
{
- //Marked serializable even though it has no state.
- [Serializable]
#if CORECLR
internal
#else
diff --git a/src/System.Private.CoreLib/shared/System/Diagnostics/ConditionalAttribute.cs b/src/System.Private.CoreLib/shared/System/Diagnostics/ConditionalAttribute.cs
index d5bca6e20..416625b77 100644
--- a/src/System.Private.CoreLib/shared/System/Diagnostics/ConditionalAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Diagnostics/ConditionalAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Diagnostics
{
- [Serializable]
[AttributeUsage(AttributeTargets.Method | AttributeTargets.Class, AllowMultiple = true)]
public sealed class ConditionalAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Diagnostics/Tracing/EventSourceException.cs b/src/System.Private.CoreLib/shared/System/Diagnostics/Tracing/EventSourceException.cs
index 88b8da93c..73e32aaf5 100644
--- a/src/System.Private.CoreLib/shared/System/Diagnostics/Tracing/EventSourceException.cs
+++ b/src/System.Private.CoreLib/shared/System/Diagnostics/Tracing/EventSourceException.cs
@@ -18,9 +18,9 @@ namespace System.Diagnostics.Tracing
/// <summary>
/// Exception that is thrown when an error occurs during EventSource operation.
/// </summary>
-#if !ES_BUILD_PCL
+#if !CORECLR && !ES_BUILD_PN && !ES_BUILD_PCL && !CORERT
[Serializable]
-#endif
+#endif // !CORECLR && !ES_BUILD_PN && !ES_BUILD_PCL && !CORERT
public class EventSourceException : Exception
{
/// <summary>
diff --git a/src/System.Private.CoreLib/shared/System/DivideByZeroException.cs b/src/System.Private.CoreLib/shared/System/DivideByZeroException.cs
index 4abd43ada..f5911f269 100644
--- a/src/System.Private.CoreLib/shared/System/DivideByZeroException.cs
+++ b/src/System.Private.CoreLib/shared/System/DivideByZeroException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class DivideByZeroException : ArithmeticException
{
public DivideByZeroException()
diff --git a/src/System.Private.CoreLib/shared/System/DllNotFoundException.cs b/src/System.Private.CoreLib/shared/System/DllNotFoundException.cs
index c0b343219..fc63bc50e 100644
--- a/src/System.Private.CoreLib/shared/System/DllNotFoundException.cs
+++ b/src/System.Private.CoreLib/shared/System/DllNotFoundException.cs
@@ -16,7 +16,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class DllNotFoundException : TypeLoadException
{
public DllNotFoundException()
diff --git a/src/System.Private.CoreLib/shared/System/DuplicateWaitObjectException.cs b/src/System.Private.CoreLib/shared/System/DuplicateWaitObjectException.cs
index da29e2ad7..d9075dfc8 100644
--- a/src/System.Private.CoreLib/shared/System/DuplicateWaitObjectException.cs
+++ b/src/System.Private.CoreLib/shared/System/DuplicateWaitObjectException.cs
@@ -18,7 +18,6 @@ namespace System
// The DuplicateWaitObjectException is thrown when an object
// appears more than once in the list of objects to WaitAll or WaitAny.
//
- [Serializable]
public class DuplicateWaitObjectException : ArgumentException
{
private static volatile String s_duplicateWaitObjectMessage = null;
diff --git a/src/System.Private.CoreLib/shared/System/EntryPointNotFoundException.cs b/src/System.Private.CoreLib/shared/System/EntryPointNotFoundException.cs
index 835d33413..0859eb4ef 100644
--- a/src/System.Private.CoreLib/shared/System/EntryPointNotFoundException.cs
+++ b/src/System.Private.CoreLib/shared/System/EntryPointNotFoundException.cs
@@ -16,7 +16,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class EntryPointNotFoundException : TypeLoadException
{
public EntryPointNotFoundException()
diff --git a/src/System.Private.CoreLib/shared/System/EventArgs.cs b/src/System.Private.CoreLib/shared/System/EventArgs.cs
index c0356613d..be12af25b 100644
--- a/src/System.Private.CoreLib/shared/System/EventArgs.cs
+++ b/src/System.Private.CoreLib/shared/System/EventArgs.cs
@@ -7,7 +7,6 @@ using System;
namespace System
{
// The base class for all event classes.
- [Serializable]
public class EventArgs
{
public static readonly EventArgs Empty = new EventArgs();
diff --git a/src/System.Private.CoreLib/shared/System/ExecutionEngineException.cs b/src/System.Private.CoreLib/shared/System/ExecutionEngineException.cs
index bebfd493a..ae3a8db8f 100644
--- a/src/System.Private.CoreLib/shared/System/ExecutionEngineException.cs
+++ b/src/System.Private.CoreLib/shared/System/ExecutionEngineException.cs
@@ -21,7 +21,6 @@ using System.Runtime.Serialization;
namespace System
{
[Obsolete("This type previously indicated an unspecified fatal error in the runtime. The runtime no longer raises this exception so this type is obsolete.")]
- [Serializable]
public sealed class ExecutionEngineException : SystemException
{
public ExecutionEngineException()
diff --git a/src/System.Private.CoreLib/shared/System/FieldAccessException.cs b/src/System.Private.CoreLib/shared/System/FieldAccessException.cs
index ac62c0fca..109bd77b9 100644
--- a/src/System.Private.CoreLib/shared/System/FieldAccessException.cs
+++ b/src/System.Private.CoreLib/shared/System/FieldAccessException.cs
@@ -13,7 +13,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class FieldAccessException : MemberAccessException
{
public FieldAccessException()
diff --git a/src/System.Private.CoreLib/shared/System/FlagsAttribute.cs b/src/System.Private.CoreLib/shared/System/FlagsAttribute.cs
index 5f8c108ae..4f3ab36bf 100644
--- a/src/System.Private.CoreLib/shared/System/FlagsAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/FlagsAttribute.cs
@@ -11,7 +11,6 @@ namespace System
// should be treated as a bitfield (or set of flags).
// An IDE may use this information to provide a richer
// development experience.
- [Serializable]
[AttributeUsage(AttributeTargets.Enum, Inherited = false)]
public class FlagsAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/FormatException.cs b/src/System.Private.CoreLib/shared/System/FormatException.cs
index c5758e11c..68e1f4fbc 100644
--- a/src/System.Private.CoreLib/shared/System/FormatException.cs
+++ b/src/System.Private.CoreLib/shared/System/FormatException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class FormatException : SystemException
{
public FormatException()
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/ChineseLunisolarCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/ChineseLunisolarCalendar.cs
index 404add093..e09011a9d 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/ChineseLunisolarCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/ChineseLunisolarCalendar.cs
@@ -14,7 +14,6 @@ namespace System.Globalization
** ChineseLunisolar 1901/01/01 2100/12/29
*/
- [Serializable]
public class ChineseLunisolarCalendar : EastAsianLunisolarCalendar
{
//
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/CultureNotFoundException.cs b/src/System.Private.CoreLib/shared/System/Globalization/CultureNotFoundException.cs
index 929f4bb00..2b333ee75 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/CultureNotFoundException.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/CultureNotFoundException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Globalization
{
- [Serializable]
public class CultureNotFoundException : ArgumentException
{
private string _invalidCultureName; // unrecognized culture name
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/DateTimeFormatInfo.cs b/src/System.Private.CoreLib/shared/System/Globalization/DateTimeFormatInfo.cs
index d3f1ea9a4..5d3239ebf 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/DateTimeFormatInfo.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/DateTimeFormatInfo.cs
@@ -49,7 +49,6 @@ namespace System.Globalization
}
- [Serializable]
public sealed class DateTimeFormatInfo : IFormatProvider, ICloneable
{
// cache for the invariant culture.
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/DaylightTime.cs b/src/System.Private.CoreLib/shared/System/Globalization/DaylightTime.cs
index b3c70e1d1..10f074dc2 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/DaylightTime.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/DaylightTime.cs
@@ -5,7 +5,6 @@
namespace System.Globalization
{
// This class represents a starting/ending time for a period of daylight saving time.
- [Serializable]
public class DaylightTime
{
private readonly DateTime _start;
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/EastAsianLunisolarCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/EastAsianLunisolarCalendar.cs
index d06b13cd7..0697b602d 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/EastAsianLunisolarCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/EastAsianLunisolarCalendar.cs
@@ -6,7 +6,6 @@ using System.Diagnostics.Contracts;
namespace System.Globalization
{
- [Serializable]
public abstract class EastAsianLunisolarCalendar : Calendar
{
internal const int LeapMonth = 0;
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/HebrewCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/HebrewCalendar.cs
index b4f54f8fb..6ba4f082f 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/HebrewCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/HebrewCalendar.cs
@@ -62,7 +62,6 @@ namespace System.Globalization
// Gregorian to Hebrew Lunar from 1583 to 2239.
- [Serializable]
public class HebrewCalendar : Calendar
{
public static readonly int HebrewEra = 1;
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/HijriCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/HijriCalendar.cs
index cafde5fbb..125248a68 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/HijriCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/HijriCalendar.cs
@@ -42,7 +42,6 @@ namespace System.Globalization
** Hijri 0001/01/01 9666/04/03
*/
- [Serializable]
public partial class HijriCalendar : Calendar
{
public static readonly int HijriEra = 1;
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/JapaneseCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/JapaneseCalendar.cs
index 4655e08a4..0db1e6517 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/JapaneseCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/JapaneseCalendar.cs
@@ -36,7 +36,6 @@ namespace System.Globalization
============================================================================*/
- [Serializable]
public partial class JapaneseCalendar : Calendar
{
internal static readonly DateTime calendarMinValue = new DateTime(1868, 9, 8);
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/JapaneseLunisolarCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/JapaneseLunisolarCalendar.cs
index 95e87f85d..a90c4e8f2 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/JapaneseLunisolarCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/JapaneseLunisolarCalendar.cs
@@ -14,7 +14,6 @@ namespace System.Globalization
** JapaneseLunisolar 1960/01/01 2049/12/29
*/
- [Serializable]
public class JapaneseLunisolarCalendar : EastAsianLunisolarCalendar
{
//
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/JulianCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/JulianCalendar.cs
index f4678c1a8..8d9429054 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/JulianCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/JulianCalendar.cs
@@ -17,7 +17,6 @@ namespace System.Globalization
//* Gregorian 0001/01/01 9999/12/31
//* Julia 0001/01/03 9999/10/19
- [Serializable]
public class JulianCalendar : Calendar
{
public static readonly int JulianEra = 1;
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/KoreanCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/KoreanCalendar.cs
index b962b1c42..ef7495f07 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/KoreanCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/KoreanCalendar.cs
@@ -23,7 +23,6 @@ namespace System.Globalization
============================================================================*/
- [Serializable]
public class KoreanCalendar : Calendar
{
//
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/KoreanLunisolarCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/KoreanLunisolarCalendar.cs
index d4c71632a..8364532c9 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/KoreanLunisolarCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/KoreanLunisolarCalendar.cs
@@ -14,7 +14,6 @@ namespace System.Globalization
** KoreanLunisolar 918/01/01 2050/13/29
*/
- [Serializable]
public class KoreanLunisolarCalendar : EastAsianLunisolarCalendar
{
//
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/NumberFormatInfo.cs b/src/System.Private.CoreLib/shared/System/Globalization/NumberFormatInfo.cs
index 179a7f68d..9fea694cc 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/NumberFormatInfo.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/NumberFormatInfo.cs
@@ -41,7 +41,6 @@ namespace System.Globalization
// CurrencySymbol "$" String used as local monetary symbol.
//
- [Serializable]
sealed public class NumberFormatInfo : IFormatProvider, ICloneable
{
// invariantInfo is constant irrespective of your current culture.
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/PersianCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/PersianCalendar.cs
index 445bbd6d0..78a081e1b 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/PersianCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/PersianCalendar.cs
@@ -19,7 +19,6 @@ namespace System.Globalization
** Persian 0001/01/01 9378/10/13
*/
- [Serializable]
public class PersianCalendar : Calendar
{
public static readonly int PersianEra = 1;
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/SortKey.cs b/src/System.Private.CoreLib/shared/System/Globalization/SortKey.cs
index c6c51a00a..d65e097cb 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/SortKey.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/SortKey.cs
@@ -19,7 +19,6 @@ using System.Diagnostics.Contracts;
namespace System.Globalization
{
- [Serializable]
public partial class SortKey
{
//--------------------------------------------------------------------//
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/StringInfo.cs b/src/System.Private.CoreLib/shared/System/Globalization/StringInfo.cs
index ca57b67eb..87d1b9f68 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/StringInfo.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/StringInfo.cs
@@ -19,7 +19,6 @@ using System.Runtime.Serialization;
namespace System.Globalization
{
- [Serializable]
public class StringInfo
{
[OptionalField(VersionAdded = 2)]
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/TaiwanCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/TaiwanCalendar.cs
index 2e735e0cb..ec4188161 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/TaiwanCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/TaiwanCalendar.cs
@@ -21,7 +21,6 @@ namespace System.Globalization
** Taiwan 01/01/01 8088/12/31
============================================================================*/
- [Serializable]
public class TaiwanCalendar : Calendar
{
//
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/TaiwanLunisolarCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/TaiwanLunisolarCalendar.cs
index 8ba1f278e..1e2ec62a7 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/TaiwanLunisolarCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/TaiwanLunisolarCalendar.cs
@@ -15,7 +15,6 @@ namespace System.Globalization
** TaiwanLunisolar 1912/01/01 2050/13/29
*/
- [Serializable]
public class TaiwanLunisolarCalendar : EastAsianLunisolarCalendar
{
// Since
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/ThaiBuddhistCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/ThaiBuddhistCalendar.cs
index 9e6e30406..e1646bfa8 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/ThaiBuddhistCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/ThaiBuddhistCalendar.cs
@@ -20,7 +20,6 @@ namespace System.Globalization
** Thai 0544/01/01 10542/12/31
============================================================================*/
- [Serializable]
public class ThaiBuddhistCalendar : Calendar
{
// Initialize our era info.
diff --git a/src/System.Private.CoreLib/shared/System/Globalization/UmAlQuraCalendar.cs b/src/System.Private.CoreLib/shared/System/Globalization/UmAlQuraCalendar.cs
index b7ba6d011..c03ac23d9 100644
--- a/src/System.Private.CoreLib/shared/System/Globalization/UmAlQuraCalendar.cs
+++ b/src/System.Private.CoreLib/shared/System/Globalization/UmAlQuraCalendar.cs
@@ -15,7 +15,6 @@ namespace System.Globalization
** UmAlQura 1318/01/01 1500/12/30
*/
- [Serializable]
public partial class UmAlQuraCalendar : Calendar
{
internal const int MinCalendarYear = 1318;
diff --git a/src/System.Private.CoreLib/shared/System/IO/DirectoryNotFoundException.cs b/src/System.Private.CoreLib/shared/System/IO/DirectoryNotFoundException.cs
index 786c2106a..04e3791a3 100644
--- a/src/System.Private.CoreLib/shared/System/IO/DirectoryNotFoundException.cs
+++ b/src/System.Private.CoreLib/shared/System/IO/DirectoryNotFoundException.cs
@@ -12,7 +12,6 @@ namespace System.IO
* the Win32 errorcode-as-HRESULT ERROR_PATH_NOT_FOUND (0x80070003)
* and STG_E_PATHNOTFOUND (0x80030003).
*/
- [Serializable]
public class DirectoryNotFoundException : IOException
{
public DirectoryNotFoundException()
diff --git a/src/System.Private.CoreLib/shared/System/IO/EndOfStreamException.cs b/src/System.Private.CoreLib/shared/System/IO/EndOfStreamException.cs
index 7c4b2b744..df9ea175e 100644
--- a/src/System.Private.CoreLib/shared/System/IO/EndOfStreamException.cs
+++ b/src/System.Private.CoreLib/shared/System/IO/EndOfStreamException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.IO
{
- [Serializable]
public class EndOfStreamException : IOException
{
public EndOfStreamException()
diff --git a/src/System.Private.CoreLib/shared/System/IO/FileLoadException.cs b/src/System.Private.CoreLib/shared/System/IO/FileLoadException.cs
index b5e197c14..dc8cf0f46 100644
--- a/src/System.Private.CoreLib/shared/System/IO/FileLoadException.cs
+++ b/src/System.Private.CoreLib/shared/System/IO/FileLoadException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.IO
{
- [Serializable]
public partial class FileLoadException : IOException
{
public FileLoadException()
diff --git a/src/System.Private.CoreLib/shared/System/IO/FileNotFoundException.cs b/src/System.Private.CoreLib/shared/System/IO/FileNotFoundException.cs
index 5d86b8f63..2a9466540 100644
--- a/src/System.Private.CoreLib/shared/System/IO/FileNotFoundException.cs
+++ b/src/System.Private.CoreLib/shared/System/IO/FileNotFoundException.cs
@@ -7,7 +7,6 @@ using System.Runtime.Serialization;
namespace System.IO
{
// Thrown when trying to access a file that doesn't exist on disk.
- [Serializable]
public partial class FileNotFoundException : IOException
{
public FileNotFoundException()
diff --git a/src/System.Private.CoreLib/shared/System/IO/PathTooLongException.cs b/src/System.Private.CoreLib/shared/System/IO/PathTooLongException.cs
index 613af051c..46e9bd657 100644
--- a/src/System.Private.CoreLib/shared/System/IO/PathTooLongException.cs
+++ b/src/System.Private.CoreLib/shared/System/IO/PathTooLongException.cs
@@ -8,7 +8,6 @@ using System.Runtime.Serialization;
namespace System.IO
{
- [Serializable]
public class PathTooLongException : IOException
{
public PathTooLongException()
diff --git a/src/System.Private.CoreLib/shared/System/IndexOutOfRangeException.cs b/src/System.Private.CoreLib/shared/System/IndexOutOfRangeException.cs
index 4969c2b86..0225a600f 100644
--- a/src/System.Private.CoreLib/shared/System/IndexOutOfRangeException.cs
+++ b/src/System.Private.CoreLib/shared/System/IndexOutOfRangeException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public sealed class IndexOutOfRangeException : SystemException
{
public IndexOutOfRangeException()
diff --git a/src/System.Private.CoreLib/shared/System/InsufficientExecutionStackException.cs b/src/System.Private.CoreLib/shared/System/InsufficientExecutionStackException.cs
index b9a4a12dd..be647e3c7 100644
--- a/src/System.Private.CoreLib/shared/System/InsufficientExecutionStackException.cs
+++ b/src/System.Private.CoreLib/shared/System/InsufficientExecutionStackException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public sealed class InsufficientExecutionStackException : SystemException
{
public InsufficientExecutionStackException()
diff --git a/src/System.Private.CoreLib/shared/System/InvalidCastException.cs b/src/System.Private.CoreLib/shared/System/InvalidCastException.cs
index 01d92b283..88ee3999b 100644
--- a/src/System.Private.CoreLib/shared/System/InvalidCastException.cs
+++ b/src/System.Private.CoreLib/shared/System/InvalidCastException.cs
@@ -12,7 +12,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class InvalidCastException : SystemException
{
public InvalidCastException()
diff --git a/src/System.Private.CoreLib/shared/System/InvalidOperationException.cs b/src/System.Private.CoreLib/shared/System/InvalidOperationException.cs
index 24a08c808..ab01183ef 100644
--- a/src/System.Private.CoreLib/shared/System/InvalidOperationException.cs
+++ b/src/System.Private.CoreLib/shared/System/InvalidOperationException.cs
@@ -16,7 +16,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class InvalidOperationException : SystemException
{
public InvalidOperationException()
diff --git a/src/System.Private.CoreLib/shared/System/InvalidProgramException.cs b/src/System.Private.CoreLib/shared/System/InvalidProgramException.cs
index 401b3a0dd..a5f798cdd 100644
--- a/src/System.Private.CoreLib/shared/System/InvalidProgramException.cs
+++ b/src/System.Private.CoreLib/shared/System/InvalidProgramException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public sealed class InvalidProgramException : SystemException
{
public InvalidProgramException()
diff --git a/src/System.Private.CoreLib/shared/System/InvalidTimeZoneException.cs b/src/System.Private.CoreLib/shared/System/InvalidTimeZoneException.cs
index 8f0751c42..09eed884d 100644
--- a/src/System.Private.CoreLib/shared/System/InvalidTimeZoneException.cs
+++ b/src/System.Private.CoreLib/shared/System/InvalidTimeZoneException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class InvalidTimeZoneException : Exception
{
public InvalidTimeZoneException()
diff --git a/src/System.Private.CoreLib/shared/System/MarshalByRefObject.cs b/src/System.Private.CoreLib/shared/System/MarshalByRefObject.cs
index 1f1739b9c..390b72832 100644
--- a/src/System.Private.CoreLib/shared/System/MarshalByRefObject.cs
+++ b/src/System.Private.CoreLib/shared/System/MarshalByRefObject.cs
@@ -4,7 +4,6 @@
namespace System
{
- [Serializable]
public abstract class MarshalByRefObject
{
protected MarshalByRefObject()
diff --git a/src/System.Private.CoreLib/shared/System/MemberAccessException.cs b/src/System.Private.CoreLib/shared/System/MemberAccessException.cs
index 54eee67b0..074699ded 100644
--- a/src/System.Private.CoreLib/shared/System/MemberAccessException.cs
+++ b/src/System.Private.CoreLib/shared/System/MemberAccessException.cs
@@ -15,7 +15,6 @@ namespace System
// The MemberAccessException is thrown when trying to access a class
// member fails.
//
- [Serializable]
public class MemberAccessException : SystemException
{
// Creates a new MemberAccessException with its message string set to
diff --git a/src/System.Private.CoreLib/shared/System/MethodAccessException.cs b/src/System.Private.CoreLib/shared/System/MethodAccessException.cs
index 2ecbd14d6..515458cb1 100644
--- a/src/System.Private.CoreLib/shared/System/MethodAccessException.cs
+++ b/src/System.Private.CoreLib/shared/System/MethodAccessException.cs
@@ -13,7 +13,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class MethodAccessException : MemberAccessException
{
public MethodAccessException()
diff --git a/src/System.Private.CoreLib/shared/System/MissingMethodException.cs b/src/System.Private.CoreLib/shared/System/MissingMethodException.cs
index 07d428967..2bb92e1a5 100644
--- a/src/System.Private.CoreLib/shared/System/MissingMethodException.cs
+++ b/src/System.Private.CoreLib/shared/System/MissingMethodException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class MissingMethodException : MissingMemberException
{
public MissingMethodException()
diff --git a/src/System.Private.CoreLib/shared/System/MulticastNotSupportedException.cs b/src/System.Private.CoreLib/shared/System/MulticastNotSupportedException.cs
index 4fcaa9857..5b1f41e69 100644
--- a/src/System.Private.CoreLib/shared/System/MulticastNotSupportedException.cs
+++ b/src/System.Private.CoreLib/shared/System/MulticastNotSupportedException.cs
@@ -11,7 +11,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public sealed class MulticastNotSupportedException : SystemException
{
public MulticastNotSupportedException()
diff --git a/src/System.Private.CoreLib/shared/System/NotFiniteNumberException.cs b/src/System.Private.CoreLib/shared/System/NotFiniteNumberException.cs
index 5bc8df1e2..f14f3a357 100644
--- a/src/System.Private.CoreLib/shared/System/NotFiniteNumberException.cs
+++ b/src/System.Private.CoreLib/shared/System/NotFiniteNumberException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class NotFiniteNumberException : ArithmeticException
{
private double _offendingNumber;
diff --git a/src/System.Private.CoreLib/shared/System/NotImplementedException.cs b/src/System.Private.CoreLib/shared/System/NotImplementedException.cs
index 4d141eac8..7d562ed08 100644
--- a/src/System.Private.CoreLib/shared/System/NotImplementedException.cs
+++ b/src/System.Private.CoreLib/shared/System/NotImplementedException.cs
@@ -16,7 +16,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class NotImplementedException : SystemException
{
public NotImplementedException()
diff --git a/src/System.Private.CoreLib/shared/System/NotSupportedException.cs b/src/System.Private.CoreLib/shared/System/NotSupportedException.cs
index 21b2d54a4..6d68b07e2 100644
--- a/src/System.Private.CoreLib/shared/System/NotSupportedException.cs
+++ b/src/System.Private.CoreLib/shared/System/NotSupportedException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class NotSupportedException : SystemException
{
public NotSupportedException()
diff --git a/src/System.Private.CoreLib/shared/System/NullReferenceException.cs b/src/System.Private.CoreLib/shared/System/NullReferenceException.cs
index 0aa5c6197..fb9886805 100644
--- a/src/System.Private.CoreLib/shared/System/NullReferenceException.cs
+++ b/src/System.Private.CoreLib/shared/System/NullReferenceException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class NullReferenceException : SystemException
{
public NullReferenceException()
diff --git a/src/System.Private.CoreLib/shared/System/ObjectDisposedException.cs b/src/System.Private.CoreLib/shared/System/ObjectDisposedException.cs
index abb7c89da..abeefca59 100644
--- a/src/System.Private.CoreLib/shared/System/ObjectDisposedException.cs
+++ b/src/System.Private.CoreLib/shared/System/ObjectDisposedException.cs
@@ -11,7 +11,6 @@ namespace System
/// <para> The exception that is thrown when accessing an object that was
/// disposed.</para>
/// </devdoc>
- [Serializable]
public class ObjectDisposedException : InvalidOperationException
{
private String _objectName;
diff --git a/src/System.Private.CoreLib/shared/System/ObsoleteAttribute.cs b/src/System.Private.CoreLib/shared/System/ObsoleteAttribute.cs
index f18368599..a63db137f 100644
--- a/src/System.Private.CoreLib/shared/System/ObsoleteAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/ObsoleteAttribute.cs
@@ -21,7 +21,6 @@ namespace System
// error. (this would be used if the actual implementation of the obsolete
// method's implementation had changed).
//
- [Serializable]
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Enum |
AttributeTargets.Interface | AttributeTargets.Constructor | AttributeTargets.Method | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Delegate
, Inherited = false)]
diff --git a/src/System.Private.CoreLib/shared/System/OperationCanceledException.cs b/src/System.Private.CoreLib/shared/System/OperationCanceledException.cs
index 826561776..cd1f3285b 100644
--- a/src/System.Private.CoreLib/shared/System/OperationCanceledException.cs
+++ b/src/System.Private.CoreLib/shared/System/OperationCanceledException.cs
@@ -17,7 +17,6 @@ using System.Threading;
namespace System
{
- [Serializable]
public class OperationCanceledException : SystemException
{
[NonSerialized]
diff --git a/src/System.Private.CoreLib/shared/System/OverflowException.cs b/src/System.Private.CoreLib/shared/System/OverflowException.cs
index e28c688dd..d32df8b39 100644
--- a/src/System.Private.CoreLib/shared/System/OverflowException.cs
+++ b/src/System.Private.CoreLib/shared/System/OverflowException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class OverflowException : ArithmeticException
{
public OverflowException()
diff --git a/src/System.Private.CoreLib/shared/System/PlatformNotSupportedException.cs b/src/System.Private.CoreLib/shared/System/PlatformNotSupportedException.cs
index d2370b392..fa708c921 100644
--- a/src/System.Private.CoreLib/shared/System/PlatformNotSupportedException.cs
+++ b/src/System.Private.CoreLib/shared/System/PlatformNotSupportedException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class PlatformNotSupportedException : NotSupportedException
{
public PlatformNotSupportedException()
diff --git a/src/System.Private.CoreLib/shared/System/Random.cs b/src/System.Private.CoreLib/shared/System/Random.cs
index a66a9ea42..4affed8a1 100644
--- a/src/System.Private.CoreLib/shared/System/Random.cs
+++ b/src/System.Private.CoreLib/shared/System/Random.cs
@@ -18,7 +18,6 @@ using System.Diagnostics.Contracts;
namespace System
{
- [Serializable]
public class Random
{
//
diff --git a/src/System.Private.CoreLib/shared/System/RankException.cs b/src/System.Private.CoreLib/shared/System/RankException.cs
index 612d0f086..8762aa2d6 100644
--- a/src/System.Private.CoreLib/shared/System/RankException.cs
+++ b/src/System.Private.CoreLib/shared/System/RankException.cs
@@ -16,7 +16,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class RankException : SystemException
{
public RankException()
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/AmbiguousMatchException.cs b/src/System.Private.CoreLib/shared/System/Reflection/AmbiguousMatchException.cs
index 459a19cb7..4e14e1f1b 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/AmbiguousMatchException.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/AmbiguousMatchException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Reflection
{
- [Serializable]
public sealed class AmbiguousMatchException : SystemException
{
public AmbiguousMatchException()
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/CustomAttributeFormatException.cs b/src/System.Private.CoreLib/shared/System/Reflection/CustomAttributeFormatException.cs
index 6e1154050..29bf7f099 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/CustomAttributeFormatException.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/CustomAttributeFormatException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Reflection
{
- [Serializable]
public class CustomAttributeFormatException : FormatException
{
public CustomAttributeFormatException()
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/DefaultMemberAttribute.cs b/src/System.Private.CoreLib/shared/System/Reflection/DefaultMemberAttribute.cs
index 351143371..585fdb07c 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/DefaultMemberAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/DefaultMemberAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Reflection
{
- [Serializable]
[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Interface)]
public sealed class DefaultMemberAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/InvalidFilterCriteriaException.cs b/src/System.Private.CoreLib/shared/System/Reflection/InvalidFilterCriteriaException.cs
index e3f882c40..c7644b8a8 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/InvalidFilterCriteriaException.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/InvalidFilterCriteriaException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Reflection
{
- [Serializable]
public class InvalidFilterCriteriaException : ApplicationException
{
public InvalidFilterCriteriaException()
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/MemberInfoSerializationHolder.cs b/src/System.Private.CoreLib/shared/System/Reflection/MemberInfoSerializationHolder.cs
index dfc56667b..ee14ab2ca 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/MemberInfoSerializationHolder.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/MemberInfoSerializationHolder.cs
@@ -9,7 +9,6 @@ using System.Diagnostics.Contracts;
namespace System.Reflection
{
- [Serializable]
#if CORECLR
internal
#else
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/Missing.cs b/src/System.Private.CoreLib/shared/System/Reflection/Missing.cs
index fa32d43cc..178291040 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/Missing.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/Missing.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Reflection
{
- [Serializable]
public sealed class Missing : ISerializable
{
public static readonly Missing Value = new Missing();
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/ParameterModifier.cs b/src/System.Private.CoreLib/shared/System/Reflection/ParameterModifier.cs
index 18d6cf669..640fee284 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/ParameterModifier.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/ParameterModifier.cs
@@ -4,7 +4,6 @@
namespace System.Reflection
{
- [Serializable]
public struct ParameterModifier
{
private readonly bool[] _byRef;
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/Pointer.cs b/src/System.Private.CoreLib/shared/System/Reflection/Pointer.cs
index 13a5efff4..d93e5b014 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/Pointer.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/Pointer.cs
@@ -7,7 +7,6 @@ using System.Runtime.Serialization;
namespace System.Reflection
{
- [Serializable]
[CLSCompliant(false)]
public sealed unsafe class Pointer : ISerializable
{
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/ReflectionTypeLoadException.cs b/src/System.Private.CoreLib/shared/System/Reflection/ReflectionTypeLoadException.cs
index 772620cf8..1a59c20e7 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/ReflectionTypeLoadException.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/ReflectionTypeLoadException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Reflection
{
- [Serializable]
public sealed class ReflectionTypeLoadException : SystemException, ISerializable
{
public ReflectionTypeLoadException(Type[] classes, Exception[] exceptions)
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/StrongNameKeyPair.cs b/src/System.Private.CoreLib/shared/System/Reflection/StrongNameKeyPair.cs
index c04ddd6d1..03fbb91be 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/StrongNameKeyPair.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/StrongNameKeyPair.cs
@@ -7,7 +7,6 @@ using System.Runtime.Serialization;
namespace System.Reflection
{
- [Serializable]
public class StrongNameKeyPair : IDeserializationCallback, ISerializable
{
private bool _keyPairExported;
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/TargetException.cs b/src/System.Private.CoreLib/shared/System/Reflection/TargetException.cs
index 03f8730cd..16b4a1455 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/TargetException.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/TargetException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Reflection
{
- [Serializable]
public class TargetException : ApplicationException
{
public TargetException()
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/TargetInvocationException.cs b/src/System.Private.CoreLib/shared/System/Reflection/TargetInvocationException.cs
index e934e5bde..8c98e5c0b 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/TargetInvocationException.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/TargetInvocationException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Reflection
{
- [Serializable]
public sealed class TargetInvocationException : ApplicationException
{
public TargetInvocationException(Exception inner)
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/TargetParameterCountException.cs b/src/System.Private.CoreLib/shared/System/Reflection/TargetParameterCountException.cs
index c3604548e..befe6b2f1 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/TargetParameterCountException.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/TargetParameterCountException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Reflection
{
- [Serializable]
public sealed class TargetParameterCountException : ApplicationException
{
public TargetParameterCountException()
diff --git a/src/System.Private.CoreLib/shared/System/Reflection/TypeDelegator.cs b/src/System.Private.CoreLib/shared/System/Reflection/TypeDelegator.cs
index a301ddc11..bcbff05d6 100644
--- a/src/System.Private.CoreLib/shared/System/Reflection/TypeDelegator.cs
+++ b/src/System.Private.CoreLib/shared/System/Reflection/TypeDelegator.cs
@@ -10,7 +10,6 @@ using CultureInfo = System.Globalization.CultureInfo;
namespace System.Reflection
{
- [Serializable]
public class TypeDelegator : TypeInfo
{
public override bool IsAssignableFrom(TypeInfo typeInfo)
diff --git a/src/System.Private.CoreLib/shared/System/Resources/MissingManifestResourceException.cs b/src/System.Private.CoreLib/shared/System/Resources/MissingManifestResourceException.cs
index 70f41f4d9..ce2c4c7e8 100644
--- a/src/System.Private.CoreLib/shared/System/Resources/MissingManifestResourceException.cs
+++ b/src/System.Private.CoreLib/shared/System/Resources/MissingManifestResourceException.cs
@@ -7,7 +7,6 @@ using System.Runtime.Serialization;
namespace System.Resources
{
- [Serializable]
public class MissingManifestResourceException : SystemException
{
public MissingManifestResourceException()
diff --git a/src/System.Private.CoreLib/shared/System/Resources/MissingSatelliteAssemblyException.cs b/src/System.Private.CoreLib/shared/System/Resources/MissingSatelliteAssemblyException.cs
index b343e0cfb..8a9289b0a 100644
--- a/src/System.Private.CoreLib/shared/System/Resources/MissingSatelliteAssemblyException.cs
+++ b/src/System.Private.CoreLib/shared/System/Resources/MissingSatelliteAssemblyException.cs
@@ -20,7 +20,6 @@ using System.Runtime.Serialization;
namespace System.Resources
{
- [Serializable]
public class MissingSatelliteAssemblyException : SystemException
{
private String _cultureName;
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/AsyncStateMachineAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/AsyncStateMachineAttribute.cs
index 198ed3d0e..66c9175ee 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/AsyncStateMachineAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/AsyncStateMachineAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Method, Inherited = false, AllowMultiple = false)]
public sealed class AsyncStateMachineAttribute : StateMachineAttribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilationRelaxationsAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilationRelaxationsAttribute.cs
index 1f100bd41..d6da23fdf 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilationRelaxationsAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilationRelaxationsAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Assembly | AttributeTargets.Module | AttributeTargets.Class | AttributeTargets.Method)]
public class CompilationRelaxationsAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilerGeneratedAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilerGeneratedAttribute.cs
index 3da2a95ae..1c05abd1f 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilerGeneratedAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilerGeneratedAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.All, Inherited = true)]
public sealed class CompilerGeneratedAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilerGlobalScopeAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilerGlobalScopeAttribute.cs
index 22fa69420..752295e87 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilerGlobalScopeAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/CompilerGlobalScopeAttribute.cs
@@ -6,7 +6,6 @@ namespace System.Runtime.CompilerServices
{
// Attribute used to communicate to the VS7 debugger that a class should be treated as if it has global scope.
- [Serializable]
[AttributeUsage(AttributeTargets.Class)]
public class CompilerGlobalScopeAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/DefaultDependencyAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/DefaultDependencyAttribute.cs
index f5419d413..4c1f48921 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/DefaultDependencyAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/DefaultDependencyAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Assembly)]
public sealed class DefaultDependencyAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/DependencyAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/DependencyAttribute.cs
index 56f4242bb..0fe07edc9 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/DependencyAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/DependencyAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)]
public sealed class DependencyAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/FixedAddressValueTypeAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/FixedAddressValueTypeAttribute.cs
index baf582424..8dc6c4312 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/FixedAddressValueTypeAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/FixedAddressValueTypeAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Field)]
public sealed class FixedAddressValueTypeAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IndexerNameAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IndexerNameAttribute.cs
index 65653a44d..ea843b3da 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IndexerNameAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IndexerNameAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Property, Inherited = true)]
public sealed class IndexerNameAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IteratorStateMachineAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IteratorStateMachineAttribute.cs
index 5ac391802..53afc9566 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IteratorStateMachineAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IteratorStateMachineAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Method, Inherited = false, AllowMultiple = false)]
public sealed class IteratorStateMachineAttribute : StateMachineAttribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/ReferenceAssemblyAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/ReferenceAssemblyAttribute.cs
index 6e307e72a..f3842ec56 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/ReferenceAssemblyAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/ReferenceAssemblyAttribute.cs
@@ -15,7 +15,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Assembly, AllowMultiple = false)]
public sealed class ReferenceAssemblyAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/RuntimeCompatibilityAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/RuntimeCompatibilityAttribute.cs
index 55dba0d11..609c56033 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/RuntimeCompatibilityAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/RuntimeCompatibilityAttribute.cs
@@ -13,7 +13,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Assembly, Inherited = false, AllowMultiple = false)]
public sealed class RuntimeCompatibilityAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/StateMachineAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/StateMachineAttribute.cs
index 94ed5b5c7..e081d63e7 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/StateMachineAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/StateMachineAttribute.cs
@@ -6,7 +6,6 @@ using System;
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Method, Inherited = false, AllowMultiple = false)]
public class StateMachineAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/StringFreezingAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/StringFreezingAttribute.cs
index 7772a1a26..25a8bfbc2 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/StringFreezingAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/StringFreezingAttribute.cs
@@ -6,7 +6,6 @@ namespace System.Runtime.CompilerServices
{
// Custom attribute to indicate that strings should be frozen.
- [Serializable]
[AttributeUsage(AttributeTargets.Assembly, Inherited = false)]
public sealed class StringFreezingAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/UnsafeValueTypeAttribute.cs b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/UnsafeValueTypeAttribute.cs
index 162676efe..f049c89b3 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/UnsafeValueTypeAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/UnsafeValueTypeAttribute.cs
@@ -4,7 +4,6 @@
namespace System.Runtime.CompilerServices
{
- [Serializable]
[AttributeUsage(AttributeTargets.Struct)]
sealed public class UnsafeValueTypeAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/InteropServices/ExternalException.cs b/src/System.Private.CoreLib/shared/System/Runtime/InteropServices/ExternalException.cs
index d7bde79c4..f349a5bec 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/InteropServices/ExternalException.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/InteropServices/ExternalException.cs
@@ -21,7 +21,6 @@ namespace System.Runtime.InteropServices
// Base exception for COM Interop errors &; Structured Exception Handler
// exceptions.
//
- [Serializable]
public class ExternalException : SystemException
{
public ExternalException()
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/Serialization/SerializationException.cs b/src/System.Private.CoreLib/shared/System/Runtime/Serialization/SerializationException.cs
index a359daf4f..b11daa5a8 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/Serialization/SerializationException.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/Serialization/SerializationException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Runtime.Serialization
{
- [Serializable]
public class SerializationException : SystemException
{
private static String s_nullMessage = SR.SerializationException;
diff --git a/src/System.Private.CoreLib/shared/System/Runtime/Serialization/StreamingContext.cs b/src/System.Private.CoreLib/shared/System/Runtime/Serialization/StreamingContext.cs
index 1026a87d1..4fe90cad8 100644
--- a/src/System.Private.CoreLib/shared/System/Runtime/Serialization/StreamingContext.cs
+++ b/src/System.Private.CoreLib/shared/System/Runtime/Serialization/StreamingContext.cs
@@ -4,7 +4,6 @@
namespace System.Runtime.Serialization
{
- [Serializable]
public struct StreamingContext
{
private readonly object _additionalContext;
diff --git a/src/System.Private.CoreLib/shared/System/Security/CryptographicException.cs b/src/System.Private.CoreLib/shared/System/Security/CryptographicException.cs
index 89cb658aa..62613c98b 100644
--- a/src/System.Private.CoreLib/shared/System/Security/CryptographicException.cs
+++ b/src/System.Private.CoreLib/shared/System/Security/CryptographicException.cs
@@ -7,7 +7,6 @@ using System.Runtime.Serialization;
namespace System.Security.Cryptography
{
- [Serializable]
public class CryptographicException : SystemException
{
public CryptographicException()
diff --git a/src/System.Private.CoreLib/shared/System/Security/SecurityException.cs b/src/System.Private.CoreLib/shared/System/Security/SecurityException.cs
index 86e3cd463..6baba64ef 100644
--- a/src/System.Private.CoreLib/shared/System/Security/SecurityException.cs
+++ b/src/System.Private.CoreLib/shared/System/Security/SecurityException.cs
@@ -7,7 +7,6 @@ using System.Runtime.Serialization;
namespace System.Security
{
- [Serializable]
public class SecurityException : SystemException
{
public SecurityException()
diff --git a/src/System.Private.CoreLib/shared/System/Security/VerificationException.cs b/src/System.Private.CoreLib/shared/System/Security/VerificationException.cs
index 9641e1aa4..5a93b3580 100644
--- a/src/System.Private.CoreLib/shared/System/Security/VerificationException.cs
+++ b/src/System.Private.CoreLib/shared/System/Security/VerificationException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Security
{
- [Serializable]
public class VerificationException : SystemException
{
public VerificationException()
diff --git a/src/System.Private.CoreLib/shared/System/StackOverflowException.cs b/src/System.Private.CoreLib/shared/System/StackOverflowException.cs
index 0a875e737..2975253eb 100644
--- a/src/System.Private.CoreLib/shared/System/StackOverflowException.cs
+++ b/src/System.Private.CoreLib/shared/System/StackOverflowException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public sealed class StackOverflowException : SystemException
{
public StackOverflowException()
diff --git a/src/System.Private.CoreLib/shared/System/SystemException.cs b/src/System.Private.CoreLib/shared/System/SystemException.cs
index f4779a2cd..9961df39c 100644
--- a/src/System.Private.CoreLib/shared/System/SystemException.cs
+++ b/src/System.Private.CoreLib/shared/System/SystemException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class SystemException : Exception
{
public SystemException()
diff --git a/src/System.Private.CoreLib/shared/System/Text/ASCIIEncoding.cs b/src/System.Private.CoreLib/shared/System/Text/ASCIIEncoding.cs
index e5c119484..628ec9a3f 100644
--- a/src/System.Private.CoreLib/shared/System/Text/ASCIIEncoding.cs
+++ b/src/System.Private.CoreLib/shared/System/Text/ASCIIEncoding.cs
@@ -19,11 +19,9 @@ namespace System.Text
// Note: IsAlwaysNormalized remains false because 1/2 the code points are unassigned, so they'd
// use fallbacks, and we cannot guarantee that fallbacks are normalized.
- [Serializable]
public class ASCIIEncoding : Encoding
{
// Allow for devirtualization (see https://github.com/dotnet/coreclr/pull/9230)
- [Serializable]
internal sealed class ASCIIEncodingSealed : ASCIIEncoding { }
// Used by Encoding.ASCII for lazy initialization
diff --git a/src/System.Private.CoreLib/shared/System/Text/Decoder.cs b/src/System.Private.CoreLib/shared/System/Text/Decoder.cs
index b2a003037..aefe1f64b 100644
--- a/src/System.Private.CoreLib/shared/System/Text/Decoder.cs
+++ b/src/System.Private.CoreLib/shared/System/Text/Decoder.cs
@@ -21,7 +21,6 @@ namespace System.Text
// class are typically obtained through calls to the GetDecoder method
// of Encoding objects.
//
- [Serializable]
public abstract class Decoder
{
internal DecoderFallback m_fallback = null;
diff --git a/src/System.Private.CoreLib/shared/System/Text/Encoder.cs b/src/System.Private.CoreLib/shared/System/Text/Encoder.cs
index e4e91765e..c4b54ce75 100644
--- a/src/System.Private.CoreLib/shared/System/Text/Encoder.cs
+++ b/src/System.Private.CoreLib/shared/System/Text/Encoder.cs
@@ -21,7 +21,6 @@ namespace System.Text
// class are typically obtained through calls to the GetEncoder method
// of Encoding objects.
//
- [Serializable]
public abstract class Encoder
{
internal EncoderFallback m_fallback = null;
diff --git a/src/System.Private.CoreLib/shared/System/Text/EncodingInfo.cs b/src/System.Private.CoreLib/shared/System/Text/EncodingInfo.cs
index 360dd7f63..99995f759 100644
--- a/src/System.Private.CoreLib/shared/System/Text/EncodingInfo.cs
+++ b/src/System.Private.CoreLib/shared/System/Text/EncodingInfo.cs
@@ -7,7 +7,6 @@ using System.Text;
namespace System.Text
{
- [Serializable]
public sealed class EncodingInfo
{
private int iCodePage; // Code Page #
diff --git a/src/System.Private.CoreLib/shared/System/Text/EncodingNLS.cs b/src/System.Private.CoreLib/shared/System/Text/EncodingNLS.cs
index 205ae2690..835bf8fb3 100644
--- a/src/System.Private.CoreLib/shared/System/Text/EncodingNLS.cs
+++ b/src/System.Private.CoreLib/shared/System/Text/EncodingNLS.cs
@@ -23,7 +23,6 @@ namespace System.Text
// So if you change the wrappers in this class, you must change the wrappers in the other classes
// as well because they should have the same behavior.
- [Serializable]
internal abstract class EncodingNLS : Encoding
{
protected EncodingNLS(int codePage) : base(codePage)
diff --git a/src/System.Private.CoreLib/shared/System/Text/UTF32Encoding.cs b/src/System.Private.CoreLib/shared/System/Text/UTF32Encoding.cs
index e4cd6c960..450aee2a4 100644
--- a/src/System.Private.CoreLib/shared/System/Text/UTF32Encoding.cs
+++ b/src/System.Private.CoreLib/shared/System/Text/UTF32Encoding.cs
@@ -21,7 +21,6 @@ namespace System.Text
// mark is used mostly to distinguish UTF-32 text from other encodings, and doesn't
// switch the byte orderings.
- [Serializable]
public sealed class UTF32Encoding : Encoding
{
/*
@@ -1200,7 +1199,6 @@ namespace System.Text
CodePage + (_emitUTF32ByteOrderMark ? 4 : 0) + (_bigEndian ? 8 : 0);
}
- [Serializable]
private sealed class UTF32Decoder : DecoderNLS
{
// Need a place to store any extra bytes we may have picked up
diff --git a/src/System.Private.CoreLib/shared/System/Text/UTF8Encoding.cs b/src/System.Private.CoreLib/shared/System/Text/UTF8Encoding.cs
index 5cfa89018..e91b889cb 100644
--- a/src/System.Private.CoreLib/shared/System/Text/UTF8Encoding.cs
+++ b/src/System.Private.CoreLib/shared/System/Text/UTF8Encoding.cs
@@ -34,7 +34,6 @@ namespace System.Text
// used mostly to distinguish UTF-8 text from other encodings, and doesn't
// switch the byte orderings.
- [Serializable]
public class UTF8Encoding : Encoding
{
/*
@@ -53,7 +52,6 @@ namespace System.Text
private const int UTF8_CODEPAGE = 65001;
// Allow for devirtualization (see https://github.com/dotnet/coreclr/pull/9230)
- [Serializable]
internal sealed class UTF8EncodingSealed : UTF8Encoding
{
public UTF8EncodingSealed(bool encoderShouldEmitUTF8Identifier) : base(encoderShouldEmitUTF8Identifier) { }
@@ -2521,7 +2519,6 @@ namespace System.Text
UTF8_CODEPAGE + (_emitUTF8Identifier ? 1 : 0);
}
- [Serializable]
private sealed class UTF8Encoder : EncoderNLS, ISerializable
{
// We must save a high surrogate value until the next call, looking
@@ -2593,7 +2590,6 @@ namespace System.Text
}
}
- [Serializable]
private sealed class UTF8Decoder : DecoderNLS, ISerializable
{
// We'll need to remember the previous information. See the comments around definition
diff --git a/src/System.Private.CoreLib/shared/System/Text/UnicodeEncoding.cs b/src/System.Private.CoreLib/shared/System/Text/UnicodeEncoding.cs
index 0e4db9aaa..1b60b5b61 100644
--- a/src/System.Private.CoreLib/shared/System/Text/UnicodeEncoding.cs
+++ b/src/System.Private.CoreLib/shared/System/Text/UnicodeEncoding.cs
@@ -14,7 +14,6 @@ using System.Diagnostics.Contracts;
namespace System.Text
{
- [Serializable]
public class UnicodeEncoding : Encoding
{
// Used by Encoding.BigEndianUnicode/Unicode for lazy initialization
@@ -1983,7 +1982,6 @@ namespace System.Text
(byteOrderMark ? 4 : 0) + (bigEndian ? 8 : 0);
}
- [Serializable]
private sealed class Decoder : System.Text.DecoderNLS, ISerializable
{
internal int lastByte = -1;
diff --git a/src/System.Private.CoreLib/shared/System/ThreadStaticAttribute.cs b/src/System.Private.CoreLib/shared/System/ThreadStaticAttribute.cs
index 3755e65a7..c12ac1c18 100644
--- a/src/System.Private.CoreLib/shared/System/ThreadStaticAttribute.cs
+++ b/src/System.Private.CoreLib/shared/System/ThreadStaticAttribute.cs
@@ -17,7 +17,6 @@ using System;
namespace System
{
- [Serializable]
[AttributeUsage(AttributeTargets.Field, Inherited = false)]
public class ThreadStaticAttribute : Attribute
{
diff --git a/src/System.Private.CoreLib/shared/System/Threading/AbandonedMutexException.cs b/src/System.Private.CoreLib/shared/System/Threading/AbandonedMutexException.cs
index 8056a3b33..7a0169f3e 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/AbandonedMutexException.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/AbandonedMutexException.cs
@@ -14,7 +14,6 @@ using System.Runtime.Serialization;
namespace System.Threading
{
- [Serializable]
public class AbandonedMutexException : SystemException
{
private int _mutexIndex = -1;
diff --git a/src/System.Private.CoreLib/shared/System/Threading/ExecutionContext.cs b/src/System.Private.CoreLib/shared/System/Threading/ExecutionContext.cs
index 67857e9b1..b2cd71b27 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/ExecutionContext.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/ExecutionContext.cs
@@ -44,7 +44,6 @@ namespace System.Threading
}
}
- [Serializable]
public sealed class ExecutionContext : IDisposable, ISerializable
{
internal static readonly ExecutionContext Default = new ExecutionContext();
diff --git a/src/System.Private.CoreLib/shared/System/Threading/LockRecursionException.cs b/src/System.Private.CoreLib/shared/System/Threading/LockRecursionException.cs
index 2f296cb14..a9f0c5641 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/LockRecursionException.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/LockRecursionException.cs
@@ -7,7 +7,6 @@ using System.Runtime.Serialization;
namespace System.Threading
{
- [Serializable]
public class LockRecursionException : System.Exception
{
public LockRecursionException()
diff --git a/src/System.Private.CoreLib/shared/System/Threading/SemaphoreFullException.cs b/src/System.Private.CoreLib/shared/System/Threading/SemaphoreFullException.cs
index 19ac19d6e..b58313847 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/SemaphoreFullException.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/SemaphoreFullException.cs
@@ -7,7 +7,6 @@ using System.Runtime.Serialization;
namespace System.Threading
{
- [Serializable]
public class SemaphoreFullException : SystemException
{
public SemaphoreFullException() : base(SR.Threading_SemaphoreFullException)
diff --git a/src/System.Private.CoreLib/shared/System/Threading/SynchronizationLockException.cs b/src/System.Private.CoreLib/shared/System/Threading/SynchronizationLockException.cs
index 120577fdc..e21d0c382 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/SynchronizationLockException.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/SynchronizationLockException.cs
@@ -16,7 +16,6 @@ using System.Runtime.Serialization;
namespace System.Threading
{
- [Serializable]
public class SynchronizationLockException : SystemException
{
public SynchronizationLockException()
diff --git a/src/System.Private.CoreLib/shared/System/Threading/Tasks/TaskCanceledException.cs b/src/System.Private.CoreLib/shared/System/Threading/Tasks/TaskCanceledException.cs
index d7690d4c7..ee03204a5 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/Tasks/TaskCanceledException.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/Tasks/TaskCanceledException.cs
@@ -19,7 +19,6 @@ namespace System.Threading.Tasks
/// <summary>
/// Represents an exception used to communicate task cancellation.
/// </summary>
- [Serializable]
public class TaskCanceledException : OperationCanceledException
{
[NonSerialized]
diff --git a/src/System.Private.CoreLib/shared/System/Threading/Tasks/TaskSchedulerException.cs b/src/System.Private.CoreLib/shared/System/Threading/Tasks/TaskSchedulerException.cs
index 148b6300e..70e13f2c4 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/Tasks/TaskSchedulerException.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/Tasks/TaskSchedulerException.cs
@@ -20,7 +20,6 @@ namespace System.Threading.Tasks
/// Represents an exception used to communicate an invalid operation by a
/// <see cref="T:System.Threading.Tasks.TaskScheduler"/>.
/// </summary>
- [Serializable]
public class TaskSchedulerException : Exception
{
/// <summary>
diff --git a/src/System.Private.CoreLib/shared/System/Threading/ThreadAbortException.cs b/src/System.Private.CoreLib/shared/System/Threading/ThreadAbortException.cs
index e693e7192..f4e2ea6bf 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/ThreadAbortException.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/ThreadAbortException.cs
@@ -18,7 +18,6 @@ using System.Runtime.Serialization;
namespace System.Threading
{
- [Serializable]
public sealed class ThreadAbortException : SystemException
{
private ThreadAbortException()
diff --git a/src/System.Private.CoreLib/shared/System/Threading/ThreadStartException.cs b/src/System.Private.CoreLib/shared/System/Threading/ThreadStartException.cs
index 2ff77bc5f..9812de339 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/ThreadStartException.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/ThreadStartException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Threading
{
- [Serializable]
public sealed class ThreadStartException : SystemException
{
internal ThreadStartException()
diff --git a/src/System.Private.CoreLib/shared/System/Threading/ThreadStateException.cs b/src/System.Private.CoreLib/shared/System/Threading/ThreadStateException.cs
index 33bc8baee..a186acd67 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/ThreadStateException.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/ThreadStateException.cs
@@ -16,7 +16,6 @@ using System.Runtime.Serialization;
namespace System.Threading
{
- [Serializable]
public class ThreadStateException : SystemException
{
public ThreadStateException()
diff --git a/src/System.Private.CoreLib/shared/System/Threading/WaitHandleCannotBeOpenedException.cs b/src/System.Private.CoreLib/shared/System/Threading/WaitHandleCannotBeOpenedException.cs
index e44946a66..02dad4787 100644
--- a/src/System.Private.CoreLib/shared/System/Threading/WaitHandleCannotBeOpenedException.cs
+++ b/src/System.Private.CoreLib/shared/System/Threading/WaitHandleCannotBeOpenedException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System.Threading
{
- [Serializable]
public class WaitHandleCannotBeOpenedException : ApplicationException
{
public WaitHandleCannotBeOpenedException() : base(SR.Threading_WaitHandleCannotBeOpenedException)
diff --git a/src/System.Private.CoreLib/shared/System/TimeZoneNotFoundException.cs b/src/System.Private.CoreLib/shared/System/TimeZoneNotFoundException.cs
index ee21c2524..acb1b6f19 100644
--- a/src/System.Private.CoreLib/shared/System/TimeZoneNotFoundException.cs
+++ b/src/System.Private.CoreLib/shared/System/TimeZoneNotFoundException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class TimeZoneNotFoundException : Exception
{
public TimeZoneNotFoundException()
diff --git a/src/System.Private.CoreLib/shared/System/TimeoutException.cs b/src/System.Private.CoreLib/shared/System/TimeoutException.cs
index 32775a1c5..92780a818 100644
--- a/src/System.Private.CoreLib/shared/System/TimeoutException.cs
+++ b/src/System.Private.CoreLib/shared/System/TimeoutException.cs
@@ -15,7 +15,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class TimeoutException : SystemException
{
public TimeoutException()
diff --git a/src/System.Private.CoreLib/shared/System/TypeAccessException.cs b/src/System.Private.CoreLib/shared/System/TypeAccessException.cs
index 32afbdfeb..3561abe1a 100644
--- a/src/System.Private.CoreLib/shared/System/TypeAccessException.cs
+++ b/src/System.Private.CoreLib/shared/System/TypeAccessException.cs
@@ -8,7 +8,6 @@ namespace System
{
// TypeAccessException derives from TypeLoadException rather than MemberAccessException because in
// pre-v4 releases of the runtime TypeLoadException was used in lieu of a TypeAccessException.
- [Serializable]
public class TypeAccessException : TypeLoadException
{
public TypeAccessException()
diff --git a/src/System.Private.CoreLib/shared/System/TypeInitializationException.cs b/src/System.Private.CoreLib/shared/System/TypeInitializationException.cs
index 919102834..53dd80ead 100644
--- a/src/System.Private.CoreLib/shared/System/TypeInitializationException.cs
+++ b/src/System.Private.CoreLib/shared/System/TypeInitializationException.cs
@@ -19,7 +19,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public sealed class TypeInitializationException : SystemException
{
private String _typeName;
diff --git a/src/System.Private.CoreLib/shared/System/TypeUnloadedException.cs b/src/System.Private.CoreLib/shared/System/TypeUnloadedException.cs
index 33e468777..296a82065 100644
--- a/src/System.Private.CoreLib/shared/System/TypeUnloadedException.cs
+++ b/src/System.Private.CoreLib/shared/System/TypeUnloadedException.cs
@@ -6,7 +6,6 @@ using System.Runtime.Serialization;
namespace System
{
- [Serializable]
public class TypeUnloadedException : SystemException
{
public TypeUnloadedException()
diff --git a/src/System.Private.CoreLib/shared/System/UnauthorizedAccessException.cs b/src/System.Private.CoreLib/shared/System/UnauthorizedAccessException.cs
index 997358826..ceb018697 100644
--- a/src/System.Private.CoreLib/shared/System/UnauthorizedAccessException.cs
+++ b/src/System.Private.CoreLib/shared/System/UnauthorizedAccessException.cs
@@ -19,7 +19,6 @@ namespace System
{
// The UnauthorizedAccessException is thrown when access errors
// occur from IO or other OS methods.
- [Serializable]
public class UnauthorizedAccessException : SystemException
{
public UnauthorizedAccessException()
diff --git a/src/System.Private.CoreLib/shared/System/UnhandledExceptionEventArgs.cs b/src/System.Private.CoreLib/shared/System/UnhandledExceptionEventArgs.cs
index d33830181..5cde57216 100644
--- a/src/System.Private.CoreLib/shared/System/UnhandledExceptionEventArgs.cs
+++ b/src/System.Private.CoreLib/shared/System/UnhandledExceptionEventArgs.cs
@@ -4,7 +4,6 @@
namespace System
{
- [Serializable]
public class UnhandledExceptionEventArgs : EventArgs
{
private Object _exception;
diff --git a/src/System.Private.CoreLib/shared/System/UnitySerializationHolder.cs b/src/System.Private.CoreLib/shared/System/UnitySerializationHolder.cs
index f1957981d..57eed7231 100644
--- a/src/System.Private.CoreLib/shared/System/UnitySerializationHolder.cs
+++ b/src/System.Private.CoreLib/shared/System/UnitySerializationHolder.cs
@@ -12,7 +12,6 @@ using System.Diagnostics.Contracts;
namespace System
{
- [Serializable]
// Holds classes (Empty, Null, Missing) for which we guarantee that there is only ever one instance of.
#if CORECLR
internal
diff --git a/src/System.Private.CoreLib/shared/System/Void.cs b/src/System.Private.CoreLib/shared/System/Void.cs
index 5c20f634f..5162e6ad0 100644
--- a/src/System.Private.CoreLib/shared/System/Void.cs
+++ b/src/System.Private.CoreLib/shared/System/Void.cs
@@ -10,7 +10,6 @@
namespace System
{
// This class represents the void return type
- [Serializable]
public struct Void
{
}