summaryrefslogtreecommitdiff
path: root/java/java-tests/testData/codeInsight/daemonCodeAnalyzer/advHighlighting7/RejectedTypeParamsForConstructor.java
blob: cfa0d5f15dbd48e17bd3aebff18feb809ce32794 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
class Foo {
    {
        Foo f = new Foo<error descr="Type 'Foo' does not have type parameters"><String></error>();
        Foo.<String>foo();
    }

    static void foo() {}
}

class Bar {
    <T> Bar() {}
    {
      Bar b = new <String>Bar();
    }
}

class Baz {
    Baz() {}
    {
      Baz b = new <String>Baz();
    }
}