Protect SpinLock's Enter method against asynchronous exception
[mono.git] / mcs / class / corlib / System.Threading / CancellationToken.cs
index f541e770b546da30d4449d47e96c73dab07cd1a1..3cf942567febec34a66682f466478290c281dc25 100644 (file)
@@ -27,7 +27,7 @@
 using System;
 using System.Threading;
 
-#if NET_4_0 || BOOTSTRAP_NET_4_0
+#if NET_4_0
 namespace System.Threading
 {
        public struct CancellationToken
@@ -82,9 +82,9 @@ namespace System.Threading
                        return this.Source == other.Source;
                }
 
-               public override bool Equals (object obj)
+               public override bool Equals (object other)
                {
-                       return (obj is CancellationToken) ? Equals ((CancellationToken)obj) : false;
+                       return (other is CancellationToken) ? Equals ((CancellationToken)other) : false;
                }
 
                public override int GetHashCode ()
@@ -92,14 +92,14 @@ namespace System.Threading
                        return Source.GetHashCode ();
                }
 
-               public static bool operator == (CancellationToken lhs, CancellationToken rhs)
+               public static bool operator == (CancellationToken left, CancellationToken right)
                {
-                       return lhs.Equals (rhs);
+                       return left.Equals (right);
                }
 
-               public static bool operator != (CancellationToken lhs, CancellationToken rhs)
+               public static bool operator != (CancellationToken left, CancellationToken right)
                {
-                       return !lhs.Equals (rhs);
+                       return !left.Equals (right);
                }
 
                public bool CanBeCanceled {