We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 498f6d5 commit 38bbc22Copy full SHA for 38bbc22
src/java.base/share/classes/java/lang/ref/Reference.java
@@ -359,15 +359,13 @@ public void runFinalization() {
359
*/
360
@IntrinsicCandidate
361
public T get() {
362
- @SuppressWarnings("unchecked")
363
- T result = (T) get0();
364
- return result;
+ return get0();
365
}
366
367
/* Implementation of unintrinsified get(). Making get() native may lead
368
* C2 to sometimes prefer the native implementation over the intrinsic.
369
370
- private native Object get0();
+ private native T get0();
371
372
/**
373
* Tests if the referent of this reference object is {@code obj}.
0 commit comments