test/tools/javac/literals/T6891079.java

changeset 0
959103a6100f
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/test/tools/javac/literals/T6891079.java	Wed Apr 27 01:34:52 2016 +0800
     1.3 @@ -0,0 +1,12 @@
     1.4 +/* @test /nodynamiccopyright/
     1.5 + * @bug 6891079
     1.6 + * @summary Compiler allows invalid binary literals 0b and oBL
     1.7 + * @compile/fail/ref=T6891079.out -XDrawDiagnostics T6891079.java
     1.8 + */
     1.9 +
    1.10 +class Test {
    1.11 +    int bi = 0B;
    1.12 +    long bl = 0BL;
    1.13 +    int xi = 0X;
    1.14 +    long xl = 0XL;
    1.15 +}

mercurial