test/langtools/tools/javac/warnings/6594914/T6594914a.java
author erikj
Tue, 12 Sep 2017 19:03:39 +0200
changeset 47216 71c04702a3d5
parent 8236 langtools/test/tools/javac/warnings/6594914/T6594914a.java@0d8646b7c602
permissions -rw-r--r--
8187443: Forest Consolidation: Move files to unified layout Reviewed-by: darcy, ihse
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
8236
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
     1
/**
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
     2
 * @test /nodynamiccopyright/
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
     3
 * @bug 6594914
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
     4
 * @summary \\@SuppressWarnings("deprecation") does not not work for the type of a variable
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
     5
 * @compile/ref=T6594914a.out -XDrawDiagnostics -Xlint:deprecation T6594914a.java
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
     6
 */
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
     7
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
     8
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
     9
class T6747671a {
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    10
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    11
    DeprecatedClass a1; //warn
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    12
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    13
    @SuppressWarnings("deprecation")
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    14
    DeprecatedClass a2;
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    15
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    16
    <X extends DeprecatedClass> DeprecatedClass m1(DeprecatedClass a)
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    17
            throws DeprecatedClass { return null; } //warn
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    18
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    19
    @SuppressWarnings("deprecation")
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    20
    <X extends DeprecatedClass> DeprecatedClass m2(DeprecatedClass a)
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    21
            throws DeprecatedClass { return null; }
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    22
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    23
    void test() {
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    24
        DeprecatedClass a1; //warn
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    25
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    26
        @SuppressWarnings("deprecation")
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    27
        DeprecatedClass a2;
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    28
    }
0d8646b7c602 6594914: @SuppressWarnings("deprecation") does not not work for the type of a variable
mcimadamore
parents:
diff changeset
    29
}