mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 14:54:52 +02:00
8283234: Improve @jls usage in java.base
Reviewed-by: iris
This commit is contained in:
parent
9b8afce379
commit
0cf291bc31
5 changed files with 21 additions and 21 deletions
|
@ -1884,7 +1884,7 @@ public class MethodHandles {
|
|||
* as a normal class or interface has with its own defining loader.
|
||||
* This means that the hidden class may be unloaded if and only if
|
||||
* its defining loader is not reachable and thus may be reclaimed
|
||||
* by a garbage collector (JLS 12.7).
|
||||
* by a garbage collector (JLS {@jls 12.7}).
|
||||
*
|
||||
* <p> By default, a hidden class or interface may be unloaded
|
||||
* even if the class loader that is marked as its defining loader is
|
||||
|
@ -2024,7 +2024,7 @@ public class MethodHandles {
|
|||
* that {@linkplain Class#getClassLoader() defined it}.
|
||||
* This means that a class created by a class loader may be unloaded if and
|
||||
* only if its defining loader is not reachable and thus may be reclaimed
|
||||
* by a garbage collector (JLS 12.7).
|
||||
* by a garbage collector (JLS {@jls 12.7}).
|
||||
*
|
||||
* By default, however, a hidden class or interface may be unloaded even if
|
||||
* the class loader that is marked as its defining loader is
|
||||
|
@ -4757,15 +4757,15 @@ return invoker;
|
|||
* the boolean is converted to a byte value, 1 for true, 0 for false.
|
||||
* (This treatment follows the usage of the bytecode verifier.)
|
||||
* <li>If <em>T1</em> is boolean and <em>T0</em> is another primitive,
|
||||
* <em>T0</em> is converted to byte via Java casting conversion (JLS 5.5),
|
||||
* <em>T0</em> is converted to byte via Java casting conversion (JLS {@jls 5.5}),
|
||||
* and the low order bit of the result is tested, as if by {@code (x & 1) != 0}.
|
||||
* <li>If <em>T0</em> and <em>T1</em> are primitives other than boolean,
|
||||
* then a Java casting conversion (JLS 5.5) is applied.
|
||||
* then a Java casting conversion (JLS {@jls 5.5}) is applied.
|
||||
* (Specifically, <em>T0</em> will convert to <em>T1</em> by
|
||||
* widening and/or narrowing.)
|
||||
* <li>If <em>T0</em> is a reference and <em>T1</em> a primitive, an unboxing
|
||||
* conversion will be applied at runtime, possibly followed
|
||||
* by a Java casting conversion (JLS 5.5) on the primitive value,
|
||||
* by a Java casting conversion (JLS {@jls 5.5}) on the primitive value,
|
||||
* possibly followed by a conversion from byte to boolean by testing
|
||||
* the low-order bit.
|
||||
* <li>If <em>T0</em> is a reference and <em>T1</em> a primitive,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue