Removed unnecessary call to Thread.WriteVolatile. System.Threading.Volatile is intern...
authorMarcos Henrich <marcos.henrich@xamarin.com>
Thu, 4 Dec 2014 13:45:19 +0000 (13:45 +0000)
committerMarek Safar <marek.safar@gmail.com>
Mon, 2 May 2016 22:07:39 +0000 (00:07 +0200)
mcs/class/referencesource/System.Core/System/threading/ReaderWriterLockSlim/ReaderWriterLockSlim.cs

index c79fcdc14cfa605e677e709bd4708b7528301d49..09f08981e9a049bcaf3a405d34c5f33ca165d87b 100644 (file)
@@ -1152,11 +1152,7 @@ namespace System.Threading
         private void ExitMyLock()
         {
             Debug.Assert(myLock != 0, "Exiting spin lock that is not held");
-#if NET_4_5
             Volatile.Write(ref myLock, 0);
-#else
-            Thread.VolatileWrite(ref myLock, 0);
-#endif
         }
 
 #if DEBUG