test/langtools/tools/javac/api/T6265137.java
changeset 50892 a5557f24b4d4
parent 48343 d4329843abf4
child 50897 a4d7eaf58623
equal deleted inserted replaced
50891:9948ea5ea1af 50892:a5557f24b4d4
     1 /*
     1 /*
     2  * Copyright (c) 2005, 2017, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2005, 2018, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.
     7  * published by the Free Software Foundation.
    50         };
    50         };
    51         try (StandardJavaFileManager fm = javac.getStandardFileManager(dl, null, null)) {
    51         try (StandardJavaFileManager fm = javac.getStandardFileManager(dl, null, null)) {
    52             String srcdir = System.getProperty("test.src");
    52             String srcdir = System.getProperty("test.src");
    53             Iterable<? extends JavaFileObject> files =
    53             Iterable<? extends JavaFileObject> files =
    54                 fm.getJavaFileObjectsFromFiles(Arrays.asList(new File(srcdir, "T6265137a.java")));
    54                 fm.getJavaFileObjectsFromFiles(Arrays.asList(new File(srcdir, "T6265137a.java")));
    55             javac.getTask(null, fm, dl, Arrays.asList("-target","11"), null, files).call();
    55             javac.getTask(null, fm, dl, Arrays.asList("-target", "12"), null, files).call();
    56         }
    56         }
    57     }
    57     }
    58 }
    58 }