aboutsummaryrefslogtreecommitdiffstats
path: root/tests/new/MissingTypeInDeclareParents.java
blob: 7f1e18014882fbcad49c9a7ba33013e6d1bd1eac (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
import org.aspectj.testing.Tester;
import java.util.*;
import java.io.*;

/** @testcase unmatched type name in a declare parents should result in a warning in -Xlint mode */
public class MissingTypeInDeclareParents {

    public static void main(String[] args) throws Exception {
        String s = "f" + "oo";
        int x = s.indexOf("o");
        Tester.check(true, "Kilroy was here");
    }
}

class C {
}
aspect A {
    /** Xlint warning expected where FileWriter is outside code controlled by implementation */
    declare parents : String extends Runnable; // CW 20 Xlint warning 
}