changeset 10706:003f2c10f841

8069302: Deprecate Unsafe monitor methods in JDK 8u release Reviewed-by: forax, jrose
author psandoz
date Thu, 22 Jan 2015 14:54:15 +0000
parents 6997c5d62334
children bda04f4be837
files src/share/classes/sun/misc/Unsafe.java
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/classes/sun/misc/Unsafe.java	Wed Jan 21 22:22:32 2015 +0000
+++ b/src/share/classes/sun/misc/Unsafe.java	Thu Jan 22 14:54:15 2015 +0000
@@ -846,12 +846,14 @@
         throws InstantiationException;
 
     /** Lock the object.  It must get unlocked via {@link #monitorExit}. */
+    @Deprecated
     public native void monitorEnter(Object o);
 
     /**
      * Unlock the object.  It must have been locked via {@link
      * #monitorEnter}.
      */
+    @Deprecated
     public native void monitorExit(Object o);
 
     /**
@@ -859,6 +861,7 @@
      * whether the lock succeeded.  If it did, the object must be
      * unlocked via {@link #monitorExit}.
      */
+    @Deprecated
     public native boolean tryMonitorEnter(Object o);
 
     /** Throw the exception without telling the verifier. */