1 /*
   2  * @test /nodynamiccopyright/
   3  * @summary smoke negative test for datum classes
   4  * @compile/fail/ref=DatumCanNotDeclaredFieldsWithSameName.out -XDrawDiagnostics DatumCanNotDeclaredFieldsWithSameName.java
   5  */
   6 
   7 public class DatumCanNotDeclaredFieldsWithSameName {
   8     record D1(int x, int x) { }
   9 }