test/tools/javac/valhalla/minimalvalues/CheckNullCastable.java

Print this page

        

@@ -2,11 +2,11 @@
  * @test /nodynamiccopyright/
  * @summary null cannot be casted to and compared with value types.
  * @modules  java.base/jvm.internal.value
  * @compile/fail/ref=CheckNullCastable.out -XDrawDiagnostics -Werror  -Xlint:values  CheckNullCastable.java
  */
-@jvm.internal.value.DeriveValueType
+@jvm.internal.value.ValueCapableClass
 final class CheckNullCastable {
     void foo(CheckNullCastable cnc) {
         CheckNullCastable cncl = (CheckNullCastable) null;
         if (cnc != null) {};
         if (null != cnc) {};