< prev index next >
langtools/test/tools/javac/valhalla/minimalvalues/CheckSynchronized.java
Print this page
@@ -1,12 +1,12 @@
/*
* @test /nodynamiccopyright/
* @summary Check behavior of synzhronized key word on value instances and methods.
- * @modules java.base/jvm.internal.value
- * @compile/fail/ref=CheckSynchronized.out -XDrawDiagnostics -Werror -Xlint:values CheckSynchronized.java
+ * @modules jdk.incubator.mvt
+ * @compile/fail/ref=CheckSynchronized.out --should-stop:ifError=PARSE -XDrawDiagnostics -Werror -Xlint:values CheckSynchronized.java
*/
-@jvm.internal.value.ValueCapableClass
+@jdk.incubator.mvt.ValueCapableClass
final class CheckSynchronized {
synchronized void foo() { // <<-- ERROR, no monitor associated with `this'
}
void goo() {
synchronized(this) {} // <<-- ERROR, no monitor associated with `this'
< prev index next >