Skip to content

Commit

Permalink
improve wording in refersTo javadoc
Browse files Browse the repository at this point in the history
  • Loading branch information
kimbarrett committed Oct 21, 2020
1 parent ab4e519 commit 3a15b6a
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions src/java.base/share/classes/java/lang/ref/Reference.java
Expand Up @@ -343,14 +343,12 @@ public T get() {
}

/**
* Tests if this reference object refers to {@code obj}. If {@code obj} is
* {@code null}, this method returns {@code true} if this reference object
* refers to {@code null} or has been cleared.
*
* @param obj the object to compare with this reference object's
* referent, or {@code null}.
* @return {@code true} if and only if {@code obj} is the referent
* of this reference object
* Tests if the referent of this reference object is {@code obj}.
* Using a {@code null} {@code obj} returns {@code true} if the
* reference object has been cleared.
*
* @param obj the object to compare with this reference object's referent
* @return {@code true} if {@code obj} is the referent of this reference object
* @since 16
*/
public final boolean refersTo(T obj) {
Expand Down

0 comments on commit 3a15b6a

Please sign in to comment.