diff options
author | Marek Safar <marek.safar@gmail.com> | 2018-01-23 14:06:52 +0300 |
---|---|---|
committer | Marek Safar <marek.safar@gmail.com> | 2018-01-29 19:46:25 +0300 |
commit | c7837d752641a82d659cbe43609f9c908ecd206d (patch) | |
tree | 2e877923945640b62e009d981172b09febc010ff /mcs | |
parent | df24f1e8daf4f4e7c85f54c20797fc1ee0d3db84 (diff) |
Bump corefx
Diffstat (limited to 'mcs')
-rw-r--r-- | mcs/class/Microsoft.CSharp/corefx/SR.cs | 28 | ||||
-rw-r--r-- | mcs/class/System.Data/Makefile | 2 | ||||
-rw-r--r-- | mcs/class/System.Data/corefx/SR.cs | 5 | ||||
-rw-r--r-- | mcs/class/System.Data/corefx/SqlCommand.cs | 3 | ||||
-rw-r--r-- | mcs/class/System/common.sources | 5 | ||||
-rw-r--r-- | mcs/class/corlib/Makefile | 4 | ||||
-rw-r--r-- | mcs/class/corlib/corlib.dll.sources | 46 | ||||
-rw-r--r-- | mcs/class/referencesource/mscorlib/system/collections/generic/list.cs | 6 | ||||
-rw-r--r-- | mcs/class/referencesource/mscorlib/system/throwhelper.cs | 9 | ||||
-rw-r--r-- | mcs/tests/known-issues-interp-net_4_x | 1 | ||||
-rw-r--r-- | mcs/tools/mono-symbolicate/Test/symbolicate.expected | 8 |
11 files changed, 58 insertions, 59 deletions
diff --git a/mcs/class/Microsoft.CSharp/corefx/SR.cs b/mcs/class/Microsoft.CSharp/corefx/SR.cs index 7d50ecad450..41761f89801 100644 --- a/mcs/class/Microsoft.CSharp/corefx/SR.cs +++ b/mcs/class/Microsoft.CSharp/corefx/SR.cs @@ -5,15 +5,9 @@ partial class SR { public const string InternalCompilerError = "An unexpected exception occurred while binding a dynamic operation"; - public const string BindRequireArguments = "Cannot bind call with no calling object"; - public const string BindCallFailedOverloadResolution = "Overload resolution failed"; - public const string BindBinaryOperatorRequireTwoArguments = "Binary operators must be invoked with two arguments"; - public const string BindUnaryOperatorRequireOneArgument = "Unary operators must be invoked with one argument"; public const string BindPropertyFailedMethodGroup = "The name '{0}' is bound to a method and cannot be used like a property"; public const string BindPropertyFailedEvent = "The event '{0}' can only appear on the left hand side of +"; public const string BindInvokeFailedNonDelegate = "Cannot invoke a non-delegate type"; - public const string BindBinaryAssignmentRequireTwoArguments = "Binary operators cannot be invoked with one argument"; - public const string BindBinaryAssignmentFailedNullReference = "Cannot perform member assignment on a null reference"; public const string NullReferenceOnMemberException = "Cannot perform runtime binding on a null reference"; public const string BindCallToConditionalMethod = "Cannot dynamically invoke method '{0}' because it has a Conditional attribute"; public const string BindToVoidMethodButExpectResult = "Cannot implicitly convert type 'void' to 'object'"; @@ -32,18 +26,13 @@ partial class SR public const string ObjectRequired = "An object reference is required for the non-static field, method, or property '{0}'"; public const string AmbigCall = "The call is ambiguous between the following methods or properties: '{0}' and '{1}'"; public const string BadAccess = "'{0}' is inaccessible due to its protection level"; - public const string MethDelegateMismatch = "No overload for '{0}' matches delegate '{1}'"; public const string AssgLvalueExpected = "The left-hand side of an assignment must be a variable, property or indexer"; public const string NoConstructors = "The type '{0}' has no constructors defined"; - public const string BadDelegateConstructor = "The delegate '{0}' does not have a valid constructor"; public const string PropertyLacksGet = "The property or indexer '{0}' cannot be used in this context because it lacks the get accessor"; public const string ObjectProhibited = "Member '{0}' cannot be accessed with an instance reference; qualify it with a type name instead"; public const string AssgReadonly = "A readonly field cannot be assigned to (except in a constructor or a variable initializer)"; - public const string RefReadonly = "A readonly field cannot be passed ref or out (except in a constructor)"; public const string AssgReadonlyStatic = "A static readonly field cannot be assigned to (except in a static constructor or a variable initializer)"; - public const string RefReadonlyStatic = "A static readonly field cannot be passed ref or out (except in a static constructor)"; public const string AssgReadonlyProp = "Property or indexer '{0}' cannot be assigned to -- it is read only"; - public const string RefProperty = "A property or indexer may not be passed as an out or ref parameter"; public const string UnsafeNeeded = "Dynamic calls cannot be used in conjunction with pointers"; public const string BadBoolOp = "In order to be applicable as a short circuit operator a user-defined logical operator ('{0}') must have the same return type as the type of its 2 parameters"; public const string MustHaveOpTF = "The type ('{0}') must contain declarations of operator true and operator false"; @@ -53,7 +42,6 @@ partial class SR public const string InaccessibleGetter = "The property or indexer '{0}' cannot be used in this context because the get accessor is inaccessible"; public const string InaccessibleSetter = "The property or indexer '{0}' cannot be used in this context because the set accessor is inaccessible"; public const string BadArity = "Using the generic {1} '{0}' requires '{2}' type arguments"; - public const string BadTypeArgument = "The type '{0}' may not be used as a type argument"; public const string TypeArgsNotAllowed = "The {1} '{0}' cannot be used with type arguments"; public const string HasNoTypeVars = "The non-generic {1} '{0}' cannot be used with type arguments"; public const string NewConstraintNotSatisfied = "'{2}' must be a non-abstract type with a public parameterless constructor in order to use it as parameter '{1}' in the generic type or method '{0}'"; @@ -61,39 +49,26 @@ partial class SR public const string GenericConstraintNotSatisfiedNullableEnum = "The type '{3}' cannot be used as type parameter '{2}' in the generic type or method '{0}'. The nullable type '{3}' does not satisfy the constraint of '{1}'."; public const string GenericConstraintNotSatisfiedNullableInterface = "The type '{3}' cannot be used as type parameter '{2}' in the generic type or method '{0}'. The nullable type '{3}' does not satisfy the constraint of '{1}'. Nullable types can not satisfy any interface constraints."; public const string GenericConstraintNotSatisfiedValType = "The type '{3}' cannot be used as type parameter '{2}' in the generic type or method '{0}'. There is no boxing conversion from '{3}' to '{1}'."; - public const string TypeVarCantBeNull = "Cannot convert null to type parameter '{0}' because it could be a non-nullable value type. Consider using 'default({0})' instead."; - public const string BadRetType = "'{1} {0}' has the wrong return type"; public const string CantInferMethTypeArgs = "The type arguments for method '{0}' cannot be inferred from the usage. Try specifying the type arguments explicitly."; - public const string MethGrpToNonDel = "Cannot convert method group '{0}' to non-delegate type '{1}'. Did you intend to invoke the method?"; public const string RefConstraintNotSatisfied = "The type '{2}' must be a reference type in order to use it as parameter '{1}' in the generic type or method '{0}'"; public const string ValConstraintNotSatisfied = "The type '{2}' must be a non-nullable value type in order to use it as parameter '{1}' in the generic type or method '{0}'"; public const string AmbigUDConv = "Ambiguous user defined conversions '{0}' and '{1}' when converting from '{2}' to '{3}'"; public const string BindToBogus = "'{0}' is not supported by the language"; public const string CantCallSpecialMethod = "'{0}': cannot explicitly call operator or accessor"; public const string ConvertToStaticClass = "Cannot convert to static type '{0}'"; - public const string GenericArgIsStaticClass = "'{0}': static types cannot be used as type arguments"; public const string IncrementLvalueExpected = "The operand of an increment or decrement operator must be a variable, property or indexer"; - public const string BadArgCount = "No overload for method '{0}' takes '{1}' arguments"; + public const string BadArgCount = "No overload for method '{0}' takes {1} arguments"; public const string BadArgTypes = "The best overloaded method match for '{0}' has some invalid arguments"; - public const string RefLvalueExpected = "A ref or out argument must be an assignable variable"; public const string BadProtectedAccess = "Cannot access protected member '{0}' via a qualifier of type '{1}'; the qualifier must be of type '{2}' (or derived from it)"; public const string BindToBogusProp2 = "Property, indexer, or event '{0}' is not supported by the language; try directly calling accessor methods '{1}' or '{2}'"; public const string BindToBogusProp1 = "Property, indexer, or event '{0}' is not supported by the language; try directly calling accessor method '{1}'"; public const string BadDelArgCount = "Delegate '{0}' does not take '{1}' arguments"; public const string BadDelArgTypes = "Delegate '{0}' has some invalid arguments"; - public const string AssgReadonlyLocal = "Cannot assign to '{0}' because it is read-only"; - public const string RefReadonlyLocal = "Cannot pass '{0}' as a ref or out argument because it is read-only"; public const string ReturnNotLValue = "Cannot modify the return value of '{0}' because it is not a variable"; public const string AssgReadonly2 = "Members of readonly field '{0}' cannot be modified (except in a constructor or a variable initializer)"; - public const string RefReadonly2 = "Members of readonly field '{0}' cannot be passed ref or out (except in a constructor)"; public const string AssgReadonlyStatic2 = "Fields of static readonly field '{0}' cannot be assigned to (except in a static constructor or a variable initializer)"; - public const string RefReadonlyStatic2 = "Fields of static readonly field '{0}' cannot be passed ref or out (except in a static constructor)"; - public const string AssgReadonlyLocalCause = "Cannot assign to '{0}' because it is a '{1}'"; - public const string RefReadonlyLocalCause = "Cannot pass '{0}' as a ref or out argument because it is a '{1}'"; - public const string DelegateOnNullable = "Cannot bind delegate to '{0}' because it is a member of 'System.Nullable<T>'"; public const string BadCtorArgCount = "'{0}' does not contain a constructor that takes '{1}' arguments"; public const string NonInvocableMemberCalled = "Non-invocable member '{0}' cannot be used like a method."; - public const string NamedArgumentSpecificationBeforeFixedArgument = "Named argument specifications must appear after all fixed arguments have been specified"; public const string BadNamedArgument = "The best overload for '{0}' does not have a parameter named '{1}'"; public const string BadNamedArgumentForDelegateInvoke = "The delegate '{0}' does not have a parameter named '{1}'"; public const string DuplicateNamedArgument = "Named argument '{0}' cannot be specified multiple times"; @@ -101,4 +76,5 @@ partial class SR public const string TypeArgumentRequiredForStaticCall = "The first argument to dynamically-bound static or constructor call must be a Type"; public const string DynamicArgumentNeedsValue = "The runtime binder cannot bind a metaobject without a value"; public const string BindingNameCollision = "More than one type in the binding has the same full name."; + public const string BadNonTrailingNamedArgument = "Named argument '{0}' is used out-of-position but is followed by an unnamed argument"; } diff --git a/mcs/class/System.Data/Makefile b/mcs/class/System.Data/Makefile index 671eda1e8bf..913c1136c35 100644 --- a/mcs/class/System.Data/Makefile +++ b/mcs/class/System.Data/Makefile @@ -31,6 +31,8 @@ TEST_LIB_REFS = System.Core Mono.Data.Sqlite TEST_MCS_FLAGS = $(LIB_MCS_FLAGS) -nowarn:618,169,612,219,168 TEST_NUNITLITE_APP_CONFIG_GLOBAL=Test/test-config-file + +USE_XTEST_REMOTE_EXECUTOR = YES XTEST_LIB_REFS = System System.Core System.Xml Facades/System.Text.Encoding.CodePages Facades/System.Threading.Tasks Facades/System.Runtime.InteropServices.RuntimeInformation TEST_MONO_PATH = . diff --git a/mcs/class/System.Data/corefx/SR.cs b/mcs/class/System.Data/corefx/SR.cs index 056a62876dd..cdf509de4f2 100644 --- a/mcs/class/System.Data/corefx/SR.cs +++ b/mcs/class/System.Data/corefx/SR.cs @@ -458,6 +458,11 @@ partial class SR public const string DataColumns_RemoveExpression = "Cannot remove this column, because it is part of an expression: {0} = {1}."; public const string DataRow_RowInsertTwice = "The rowOrder value={0} has been found twice for table named '{1}'."; public const string Xml_ElementTypeNotFound = "Cannot find ElementType name='{0}'."; + public const string ADP_DbProviderFactories_InvariantNameNotFound = "The specified invariant name '{0}' wasn't found in the list of registered .NET Data Providers."; + public const string ADP_DbProviderFactories_NoInstance = "The requested .NET Data Provider's implementation does not have an Instance field of a System.Data.Common.DbProviderFactory derived type."; + public const string ADP_DbProviderFactories_FactoryNotLoadable = "The registered .NET Data Provider's DbProviderFactory implementation type '{0}' couldn't be loaded."; + public const string ADP_DbProviderFactories_NoAssemblyQualifiedName = "The missing .NET Data Provider's assembly qualified name is required."; + public const string ADP_DbProviderFactories_NotAFactoryType = "The type '{0}' doesn't inherit from DbProviderFactory."; public const string ADP_ConnectionAlreadyOpen = "The connection was not closed. {0}"; public const string ADP_InternalConnectionError = "Internal DbConnection Error: {0}"; public const string ADP_InvalidOffsetValue = "Invalid parameter Offset value '{0}'. The value must be greater than or equal to 0."; diff --git a/mcs/class/System.Data/corefx/SqlCommand.cs b/mcs/class/System.Data/corefx/SqlCommand.cs index c5f0c100c8f..ea1606bddd6 100644 --- a/mcs/class/System.Data/corefx/SqlCommand.cs +++ b/mcs/class/System.Data/corefx/SqlCommand.cs @@ -19,9 +19,6 @@ namespace System.Data.SqlClient } [System.Security.Permissions.HostProtectionAttribute(ExternalThreading=true)] - public IAsyncResult BeginExecuteNonQuery() => BeginExecuteNonQuery(null, null); - - [System.Security.Permissions.HostProtectionAttribute(ExternalThreading=true)] public IAsyncResult BeginExecuteXmlReader() => BeginExecuteXmlReader(null, null); [System.Security.Permissions.HostProtectionAttribute(ExternalThreading=true)] diff --git a/mcs/class/System/common.sources b/mcs/class/System/common.sources index 06dc871a292..4d688c4322a 100644 --- a/mcs/class/System/common.sources +++ b/mcs/class/System/common.sources @@ -870,6 +870,8 @@ corefx/SR.cs ../../../external/corefx/src/Common/src/System/Net/SecurityProtocol.cs ../../../external/corefx/src/Common/src/System/Net/UriScheme.cs +../../../external/corefx/src/Common/src/System/Net/WebSockets/ManagedWebSocket.cs + ../../../external/corefx/src/Common/src/System/Net/Logging/NetEventSource.Common.cs ../../../external/corefx/src/Common/src/System/Net/WebSockets/WebSocketValidate.cs @@ -906,7 +908,6 @@ corefx/SR.cs ../../../external/corefx/src/System.Net.ServicePoint/src/System/Net/SecurityProtocolType.cs -../../../external/corefx/src/System.Net.WebSockets/src/System/Net/WebSockets/ManagedWebSocket.cs ../../../external/corefx/src/System.Net.WebSockets/src/System/Net/WebSockets/ValueWebSocketReceiveResult.cs ../../../external/corefx/src/System.Net.WebSockets/src/System/Net/WebSockets/WebSocket.cs ../../../external/corefx/src/System.Net.WebSockets/src/System/Net/WebSockets/WebSocketCloseStatus.cs @@ -921,6 +922,8 @@ corefx/SR.cs ../../../external/corefx/src/System.Net.WebSockets.Client/src/System/Net/WebSockets/ClientWebSocketOptions.cs ../../../external/corefx/src/System.Net.WebSockets.Client/src/System/Net/WebSockets/WebSocketHandle.Managed.cs +../../../external/corefx/src/System.Net.WebSockets.WebSocketProtocol/src/System/Net/WebSockets/ManagedWebSocket.netstandard.cs + ../../../external/corefx/src/System.Private.Uri/src/System/UriBuilder.cs ../../../external/corefx/src/System.Runtime.Extensions/src/System/CodeDom/Compiler/IndentedTextWriter.cs diff --git a/mcs/class/corlib/Makefile b/mcs/class/corlib/Makefile index 910f7b672f4..4e7a250bf59 100644 --- a/mcs/class/corlib/Makefile +++ b/mcs/class/corlib/Makefile @@ -93,8 +93,10 @@ ifdef MONO_FEATURE_APPLE_X509 LIB_MCS_FLAGS += -d:MONO_FEATURE_APPLE_X509 endif +COREFX_FLAGS := -d:FEATURE_PORTABLE_SPAN + WARNING_ABOUT_DISABLED_WARNING=1635 -LOCAL_MCS_FLAGS = -unsafe -nostdlib -nowarn:612,618,3001,3002,3003,$(WARNING_ABOUT_DISABLED_WARNING) -d:INSIDE_CORLIB,MONO_CULTURE_DATA -d:LIBC $(REFERENCE_SOURCES_FLAGS) +LOCAL_MCS_FLAGS = -unsafe -nostdlib -nowarn:612,618,3001,3002,3003,$(WARNING_ABOUT_DISABLED_WARNING) -d:INSIDE_CORLIB,MONO_CULTURE_DATA -d:LIBC $(REFERENCE_SOURCES_FLAGS) $(COREFX_FLAGS) DEFAULT_REFERENCES = TEST_LIB_REFS = System.Core System diff --git a/mcs/class/corlib/corlib.dll.sources b/mcs/class/corlib/corlib.dll.sources index 821afe19aeb..fc5a6481370 100644 --- a/mcs/class/corlib/corlib.dll.sources +++ b/mcs/class/corlib/corlib.dll.sources @@ -1636,27 +1636,10 @@ corert/ThreadPoolBoundHandle.cs ../../../external/corert/src/Runtime.Base/src/System/Runtime/InteropServices/NativeCallableAttribute.cs -../../../external/corert/src/System.Private.CoreLib/shared/System/Tuple.cs -../../../external/corert/src/System.Private.CoreLib/shared/System/TupleExtensions.cs -../../../external/corert/src/System.Private.CoreLib/shared/System/ValueTuple.cs - -../../../external/corert/src/System.Private.CoreLib/shared/System/Collections/DictionaryEntry.cs - -../../../external/corert/src/System.Private.CoreLib/shared/System/Collections/Generic/Dictionary.cs -../../../external/corert/src/System.Private.CoreLib/shared/System/Collections/Generic/IDictionaryDebugView.cs -../../../external/corert/src/System.Private.CoreLib/shared/System/Collections/Generic/KeyValuePair.cs - ../../../external/corert/src/System.Private.CoreLib/shared/System/Diagnostics/Debug.cs -../../../external/corert/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IsReadOnlyAttribute.cs -../../../external/corert/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/IsByRefLikeAttribute.cs -../../../external/corert/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/ITuple.cs -../../../external/corert/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/RuntimeFeature.cs -../../../external/corert/src/System.Private.CoreLib/shared/System/Runtime/CompilerServices/TupleElementNamesAttribute.cs - ../../../external/corert/src/System.Private.CoreLib/shared/System/Threading/DeferredDisposableLifetime.cs - ../../../external/corert/src/System.Private.CoreLib/src/System/Array.cs ../../../external/corert/src/System.Private.CoreLib/src/System/Collections/LowLevelComparer.cs @@ -1667,6 +1650,31 @@ corert/ThreadPoolBoundHandle.cs corefx/SR.cs +../../../external/corefx/src/Common/src/CoreLib/System/Memory.cs +../../../external/corefx/src/Common/src/CoreLib/System/MemoryDebugView.cs +../../../external/corefx/src/Common/src/CoreLib/System/ReadOnlyMemory.cs +../../../external/corefx/src/Common/src/CoreLib/System/Tuple.cs +../../../external/corefx/src/Common/src/CoreLib/System/TupleExtensions.cs +../../../external/corefx/src/Common/src/CoreLib/System/ValueTuple.cs + +../../../external/corefx/src/Common/src/CoreLib/System/Buffers/IRetainable.cs +../../../external/corefx/src/Common/src/CoreLib/System/Buffers/MemoryHandle.cs +../../../external/corefx/src/Common/src/CoreLib/System/Buffers/OwnedMemory.cs + +../../../external/corefx/src/Common/src/CoreLib/System/Collections/DictionaryEntry.cs +../../../external/corefx/src/Common/src/CoreLib/System/Collections/Generic/Dictionary.cs +../../../external/corefx/src/Common/src/CoreLib/System/Collections/Generic/IDictionaryDebugView.cs +../../../external/corefx/src/Common/src/CoreLib/System/Collections/Generic/KeyValuePair.cs + +../../../external/corefx/src/Common/src/CoreLib/System/Runtime/CompilerServices/IntrinsicAttribute.cs +../../../external/corefx/src/Common/src/CoreLib/System/Runtime/CompilerServices/IsReadOnlyAttribute.cs +../../../external/corefx/src/Common/src/CoreLib/System/Runtime/CompilerServices/IsByRefLikeAttribute.cs +../../../external/corefx/src/Common/src/CoreLib/System/Runtime/CompilerServices/ITuple.cs +../../../external/corefx/src/Common/src/CoreLib/System/Runtime/CompilerServices/RuntimeFeature.cs +../../../external/corefx/src/Common/src/CoreLib/System/Runtime/CompilerServices/TupleElementNamesAttribute.cs + +../../../external/corefx/src/Common/src/CoreLib/System/Runtime/InteropServices/MemoryMarshal.cs + ../../../external/corefx/src/Common/src/System/Collections/Generic/ReferenceEqualityComparer.cs ../../../external/corefx/src/System.Collections/src/System/Collections/Generic/CollectionExtensions.cs @@ -1680,10 +1688,7 @@ corefx/SR.cs ../../../external/corefx/src/System.Collections.Concurrent/src/System/Collections/Concurrent/Partitioner.cs ../../../external/corefx/src/System.Collections.Concurrent/src/System/Collections/Concurrent/PartitionerStatic.cs -../../../external/corefx/src/System.Memory/src/System/Memory.cs -../../../external/corefx/src/System.Memory/src/System/MemoryDebugView.cs ../../../external/corefx/src/System.Memory/src/System/Pinnable.cs -../../../external/corefx/src/System.Memory/src/System/ReadOnlyMemory.cs ../../../external/corefx/src/System.Memory/src/System/ReadOnlySpan.cs ../../../external/corefx/src/System.Memory/src/System/Span.cs ../../../external/corefx/src/System.Memory/src/System/SpanDebugView.cs @@ -1696,7 +1701,6 @@ corefx/SR.cs ../../../external/corefx/src/System.Memory/src/System/ThrowHelper.cs ../../../external/corefx/src/System.Memory/src/System/Buffers/*.cs ../../../external/corefx/src/System.Memory/src/System/Buffers/Binary/*.cs -../../../external/corefx/src/System.Memory/src/System/Runtime/InteropServices/*.cs ../../../external/corefx/src/System.Runtime.InteropServices.RuntimeInformation/src/System/Runtime/InteropServices/RuntimeInformation/OSPlatform.cs ../../../external/corefx/src/System.Runtime.InteropServices.RuntimeInformation/src/System/Runtime/InteropServices/RuntimeInformation/Architecture.cs diff --git a/mcs/class/referencesource/mscorlib/system/collections/generic/list.cs b/mcs/class/referencesource/mscorlib/system/collections/generic/list.cs index 44210ced5e3..c67e7732f90 100644 --- a/mcs/class/referencesource/mscorlib/system/collections/generic/list.cs +++ b/mcs/class/referencesource/mscorlib/system/collections/generic/list.cs @@ -178,7 +178,7 @@ namespace System.Collections.Generic { get { // Following trick can reduce the range check by one if ((uint) index >= (uint)_size) { - ThrowHelper.ThrowArgumentOutOfRangeException(); + ThrowHelper.ThrowArgumentOutOfRange_IndexException(); } Contract.EndContractBlock(); #if MONO @@ -190,7 +190,7 @@ namespace System.Collections.Generic { set { if ((uint) index >= (uint)_size) { - ThrowHelper.ThrowArgumentOutOfRangeException(); + ThrowHelper.ThrowArgumentOutOfRange_IndexException(); } Contract.EndContractBlock(); _items[index] = value; @@ -883,7 +883,7 @@ namespace System.Collections.Generic { // public void RemoveAt(int index) { if ((uint)index >= (uint)_size) { - ThrowHelper.ThrowArgumentOutOfRangeException(); + ThrowHelper.ThrowArgumentOutOfRange_IndexException(); } Contract.EndContractBlock(); _size--; diff --git a/mcs/class/referencesource/mscorlib/system/throwhelper.cs b/mcs/class/referencesource/mscorlib/system/throwhelper.cs index 523f467e8ff..59a6278d5d8 100644 --- a/mcs/class/referencesource/mscorlib/system/throwhelper.cs +++ b/mcs/class/referencesource/mscorlib/system/throwhelper.cs @@ -53,9 +53,11 @@ namespace System { [Pure] internal static partial class ThrowHelper { +#if !MONO internal static void ThrowArgumentOutOfRangeException() { ThrowArgumentOutOfRangeException(ExceptionArgument.index, ExceptionResource.ArgumentOutOfRange_Index); } +#endif internal static void ThrowWrongKeyTypeArgumentException(object key, Type targetType) { throw new ArgumentException(Environment.GetResourceString("Arg_WrongType", key, targetType), "key"); @@ -147,6 +149,13 @@ namespace System { { return new ArgumentOutOfRangeException(GetArgumentName(argument), resource); } + + internal static void ThrowArgumentOutOfRange_IndexException() + { + throw GetArgumentOutOfRangeException(ExceptionArgument.index, + SR.ArgumentOutOfRange_Index); + } + internal static void ThrowIndexArgumentOutOfRange_NeedNonNegNumException() { throw GetArgumentOutOfRangeException(ExceptionArgument.index, diff --git a/mcs/tests/known-issues-interp-net_4_x b/mcs/tests/known-issues-interp-net_4_x index b697c5e0a41..9139c646a07 100644 --- a/mcs/tests/known-issues-interp-net_4_x +++ b/mcs/tests/known-issues-interp-net_4_x @@ -15,6 +15,7 @@ gtest-etree-09.cs test-269.cs test-270.cs test-399.cs +test-404.cs test-704.cs test-811.cs test-async-17.cs diff --git a/mcs/tools/mono-symbolicate/Test/symbolicate.expected b/mcs/tools/mono-symbolicate/Test/symbolicate.expected index 8d82a4df157..996f8802409 100644 --- a/mcs/tools/mono-symbolicate/Test/symbolicate.expected +++ b/mcs/tools/mono-symbolicate/Test/symbolicate.expected @@ -142,13 +142,13 @@ Stacktrace: System.ArgumentNullException: Value cannot be null. Parameter name: key at System.ThrowHelper.ThrowArgumentNullException (System.ExceptionArgument argument) in external/corefx/src/System.Memory/src/System/ThrowHelper.cs:27 - at System.Collections.Generic.Dictionary`2[TKey,TValue].FindEntry (TKey key) in external/corert/src/System.Private.CoreLib/shared/System/Collections/Generic/Dictionary.cs:369 - at System.Collections.Generic.Dictionary`2[TKey,TValue].ContainsKey (TKey key) in external/corert/src/System.Private.CoreLib/shared/System/Collections/Generic/Dictionary.cs:285 + at System.Collections.Generic.Dictionary`2[TKey,TValue].FindEntry (TKey key) in external/corefx/src/Common/src/CoreLib/System/Collections/Generic/Dictionary.cs:369 + at System.Collections.Generic.Dictionary`2[TKey,TValue].ContainsKey (TKey key) in external/corefx/src/Common/src/CoreLib/System/Collections/Generic/Dictionary.cs:285 at StackTraceDumper+<>c.<Main>b__0_15 () in mcs/tools/mono-symbolicate/Test/StackTraceDumper.cs:54 at StackTraceDumper.Catch (System.Action action) in mcs/tools/mono-symbolicate/Test/StackTraceDumper.cs:72 Stacktrace: at System.ThrowHelper.ThrowArgumentNullException (System.ExceptionArgument argument) in external/corefx/src/System.Memory/src/System/ThrowHelper.cs:27 - at System.Collections.Generic.Dictionary`2[TKey,TValue].FindEntry (TKey key) in external/corert/src/System.Private.CoreLib/shared/System/Collections/Generic/Dictionary.cs:369 - at System.Collections.Generic.Dictionary`2[TKey,TValue].ContainsKey (TKey key) in external/corert/src/System.Private.CoreLib/shared/System/Collections/Generic/Dictionary.cs:285 + at System.Collections.Generic.Dictionary`2[TKey,TValue].FindEntry (TKey key) in external/corefx/src/Common/src/CoreLib/System/Collections/Generic/Dictionary.cs:369 + at System.Collections.Generic.Dictionary`2[TKey,TValue].ContainsKey (TKey key) in external/corefx/src/Common/src/CoreLib/System/Collections/Generic/Dictionary.cs:285 at StackTraceDumper+<>c.<Main>b__0_15 () in mcs/tools/mono-symbolicate/Test/StackTraceDumper.cs:54 at StackTraceDumper.Catch (System.Action action) in mcs/tools/mono-symbolicate/Test/StackTraceDumper.cs:72 |