Correct parameter names.
authorStephen A. Imhoff <clockwork-muse@outlook.com>
Wed, 26 Oct 2016 07:08:10 +0000 (00:08 -0700)
committerStephen A. Imhoff <clockwork-muse@outlook.com>
Fri, 28 Oct 2016 04:46:36 +0000 (21:46 -0700)
src/mscorlib/src/System/Globalization/IdnMapping.cs
src/mscorlib/src/System/Reflection/Assembly.cs
src/mscorlib/src/System/Reflection/Emit/TypeBuilder.cs
src/mscorlib/src/System/Runtime/InteropServices/Marshal.cs

index 7b8221d..e6e313f 100644 (file)
@@ -401,7 +401,7 @@ namespace System.Globalization
                     // If its too far between dots then fail
                     if (i - iLastDot > M_labelLimit + 1)
                         throw new ArgumentException(Environment.GetResourceString(
-                            "Argument_IdnBadLabelSize"), "Unicode");
+                            "Argument_IdnBadLabelSize"), nameof(unicode));
 
                     // If validating Std3, then char before dot can't be - char
                     if (bUseStd3 && i > 0)
index e9be890..6d3398c 100644 (file)
@@ -1653,7 +1653,7 @@ namespace System.Reflection
             RuntimeType attributeRuntimeType = attributeType.UnderlyingSystemType as RuntimeType;
 
             if (attributeRuntimeType == null) 
-                throw new ArgumentException(Environment.GetResourceString("Arg_MustBeType"),"caType");
+                throw new ArgumentException(Environment.GetResourceString("Arg_MustBeType"),nameof(attributeType));
 
             return CustomAttribute.IsDefined(this, attributeRuntimeType);
         }
index 89a3afd..3414a8d 100644 (file)
@@ -1532,7 +1532,7 @@ namespace System.Reflection.Emit {
             RuntimeType attributeRuntimeType = attributeType.UnderlyingSystemType as RuntimeType;
 
             if (attributeRuntimeType == null)
-                throw new ArgumentException(Environment.GetResourceString("Arg_MustBeType"),"caType");
+                throw new ArgumentException(Environment.GetResourceString("Arg_MustBeType"),nameof(attributeType));
 
             return CustomAttribute.IsDefined(m_bakedRuntimeType, attributeRuntimeType, inherit);
         }
index 0486eb4..3ca34e1 100644 (file)
@@ -1035,7 +1035,7 @@ namespace System.Runtime.InteropServices
             RuntimeType rt = structureType.UnderlyingSystemType as RuntimeType;
 
             if (rt == null)
-                throw new ArgumentException(Environment.GetResourceString("Arg_MustBeType"), "type");
+                throw new ArgumentException(Environment.GetResourceString("Arg_MustBeType"), nameof(structureType));
 
             StackCrawlMark stackMark = StackCrawlMark.LookForMyCaller;