|
|
a0c002 |
diff -ur a/org/eclipse/jdt/internal/compiler/ast/FakedTrackingVariable.java b/org/eclipse/jdt/internal/compiler/ast/FakedTrackingVariable.java
|
|
|
a0c002 |
--- a/org/eclipse/jdt/internal/compiler/ast/FakedTrackingVariable.java 2016-02-03 10:02:08.000000000 -0500
|
|
|
a0c002 |
+++ b/org/eclipse/jdt/internal/compiler/ast/FakedTrackingVariable.java 2016-05-17 16:35:21.796601241 -0400
|
|
|
a0c002 |
@@ -776,7 +776,7 @@
|
|
|
a0c002 |
}
|
|
|
a0c002 |
|
|
|
a0c002 |
public IteratorForReporting(List<FakedTrackingVariable> variables, Scope scope, boolean atExit) {
|
|
|
a0c002 |
- this.varSet = new HashSet<>(variables);
|
|
|
a0c002 |
+ this.varSet = new HashSet<FakedTrackingVariable>(variables);
|
|
|
a0c002 |
this.scope = scope;
|
|
|
a0c002 |
this.atExit = atExit;
|
|
|
a0c002 |
setUpForStage(Stage.OuterLess);
|
|
|
a0c002 |
diff -ur a/org/eclipse/jdt/internal/compiler/Compiler.java b/org/eclipse/jdt/internal/compiler/Compiler.java
|
|
|
a0c002 |
--- a/org/eclipse/jdt/internal/compiler/Compiler.java 2016-02-03 10:02:08.000000000 -0500
|
|
|
a0c002 |
+++ b/org/eclipse/jdt/internal/compiler/Compiler.java 2016-05-17 16:35:21.789601239 -0400
|
|
|
a0c002 |
@@ -489,7 +489,7 @@
|
|
|
a0c002 |
for (CategorizedProblem problem : errors) {
|
|
|
a0c002 |
if (problem.getCategoryID() == CategorizedProblem.CAT_UNSPECIFIED) {
|
|
|
a0c002 |
if (this.aptProblems == null) {
|
|
|
a0c002 |
- this.aptProblems = new HashMap<>();
|
|
|
a0c002 |
+ this.aptProblems = new HashMap<String, APTProblem[]>();
|
|
|
a0c002 |
}
|
|
|
a0c002 |
APTProblem[] problems = this.aptProblems.get(new String(unitDecl.getFileName()));
|
|
|
a0c002 |
if (problems == null) {
|
|
|
a0c002 |
diff -ur a/org/eclipse/jdt/internal/compiler/lookup/InferenceContext18.java b/org/eclipse/jdt/internal/compiler/lookup/InferenceContext18.java
|
|
|
a0c002 |
--- a/org/eclipse/jdt/internal/compiler/lookup/InferenceContext18.java 2016-02-03 10:02:08.000000000 -0500
|
|
|
a0c002 |
+++ b/org/eclipse/jdt/internal/compiler/lookup/InferenceContext18.java 2016-05-17 16:35:21.810601244 -0400
|
|
|
a0c002 |
@@ -1113,9 +1113,9 @@
|
|
|
a0c002 |
// "Given a set of inference variables to resolve, let V be the union of this set and
|
|
|
a0c002 |
// all variables upon which the resolution of at least one variable in this set depends."
|
|
|
a0c002 |
Set<InferenceVariable> v = new HashSet<InferenceVariable>();
|
|
|
a0c002 |
- Map<InferenceVariable,Set<InferenceVariable>> dependencies = new HashMap<>(); // compute only once, store for the final loop over 'v'.
|
|
|
a0c002 |
+ Map<InferenceVariable,Set<InferenceVariable>> dependencies = new HashMap<InferenceVariable,Set<InferenceVariable>>(); // compute only once, store for the final loop over 'v'.
|
|
|
a0c002 |
for (InferenceVariable iv : subSet) {
|
|
|
a0c002 |
- Set<InferenceVariable> tmp = new HashSet<>();
|
|
|
a0c002 |
+ Set<InferenceVariable> tmp = new HashSet<InferenceVariable>();
|
|
|
a0c002 |
addDependencies(bounds, tmp, iv);
|
|
|
a0c002 |
dependencies.put(iv, tmp);
|
|
|
a0c002 |
v.addAll(tmp);
|
|
|
a0c002 |
@@ -1131,7 +1131,7 @@
|
|
|
a0c002 |
// "... if αi depends on the resolution of a variable β, then either β has an instantiation or there is some j such that β = αj; ..."
|
|
|
a0c002 |
Set<InferenceVariable> set = dependencies.get(currentVariable);
|
|
|
a0c002 |
if (set == null) // not an element of the original subSet, still need to fetch this var's dependencies
|
|
|
a0c002 |
- addDependencies(bounds, set = new HashSet<>(), currentVariable);
|
|
|
a0c002 |
+ addDependencies(bounds, set = new HashSet<InferenceVariable>(), currentVariable);
|
|
|
a0c002 |
// "... and ii) there exists no non-empty proper subset of { α1, ..., αn } with this property."
|
|
|
a0c002 |
int cur = set.size();
|
|
|
a0c002 |
if (cur == 1)
|
|
|
a0c002 |
diff -ur a/org/eclipse/jdt/internal/compiler/util/Util.java b/org/eclipse/jdt/internal/compiler/util/Util.java
|
|
|
a0c002 |
--- a/org/eclipse/jdt/internal/compiler/util/Util.java 2016-02-03 10:02:08.000000000 -0500
|
|
|
a0c002 |
+++ b/org/eclipse/jdt/internal/compiler/util/Util.java 2016-05-17 16:35:21.802601243 -0400
|
|
|
a0c002 |
@@ -1125,7 +1125,7 @@
|
|
|
a0c002 |
bootclasspathProperty = System.getProperty("org.apache.harmony.boot.class.path"); //$NON-NLS-1$
|
|
|
a0c002 |
}
|
|
|
a0c002 |
}
|
|
|
a0c002 |
- List<String> filePaths = new ArrayList<>();
|
|
|
a0c002 |
+ List<String> filePaths = new ArrayList<String>();
|
|
|
a0c002 |
if ((bootclasspathProperty != null) && (bootclasspathProperty.length() != 0)) {
|
|
|
a0c002 |
StringTokenizer tokenizer = new StringTokenizer(bootclasspathProperty, File.pathSeparator);
|
|
|
a0c002 |
while (tokenizer.hasMoreTokens()) {
|
|
|
a0c002 |
diff -ur a/org/eclipse/jdt/internal/compiler/batch/ClasspathJsr199.java b/org/eclipse/jdt/internal/compiler/batch/ClasspathJsr199.java
|
|
|
a0c002 |
--- a/org/eclipse/jdt/internal/compiler/batch/ClasspathJsr199.java 2016-02-03 10:01:58.000000000 -0500
|
|
|
a0c002 |
+++ b/org/eclipse/jdt/internal/compiler/batch/ClasspathJsr199.java 2016-05-17 16:35:21.790601240 -0400
|
|
|
a0c002 |
@@ -31,7 +31,7 @@
|
|
|
a0c002 |
|
|
|
a0c002 |
@SuppressWarnings({ "rawtypes", "unchecked" })
|
|
|
a0c002 |
public class ClasspathJsr199 extends ClasspathLocation {
|
|
|
a0c002 |
- private static final Set<JavaFileObject.Kind> fileTypes = new HashSet<>();
|
|
|
a0c002 |
+ private static final Set<JavaFileObject.Kind> fileTypes = new HashSet<JavaFileObject.Kind>();
|
|
|
a0c002 |
|
|
|
a0c002 |
static {
|
|
|
a0c002 |
fileTypes.add(JavaFileObject.Kind.CLASS);
|
|
|
a0c002 |
@@ -78,11 +75,17 @@
|
|
|
a0c002 |
if (jfo == null)
|
|
|
a0c002 |
return null; // most common case
|
|
|
a0c002 |
|
|
|
a0c002 |
- try (InputStream inputStream = jfo.openInputStream()) {
|
|
|
a0c002 |
+ InputStream inputStream = null;
|
|
|
a0c002 |
+ try {
|
|
|
a0c002 |
+ inputStream = jfo.openInputStream();
|
|
|
a0c002 |
ClassFileReader reader = ClassFileReader.read(inputStream, qualifiedBinaryFileName);
|
|
|
a0c002 |
if (reader != null) {
|
|
|
a0c002 |
return new NameEnvironmentAnswer(reader, fetchAccessRestriction(qualifiedBinaryFileName));
|
|
|
a0c002 |
}
|
|
|
a0c002 |
+ } finally {
|
|
|
a0c002 |
+ if (inputStream != null) {
|
|
|
a0c002 |
+ inputStream.close();
|
|
|
a0c002 |
+ }
|
|
|
a0c002 |
}
|
|
|
a0c002 |
} catch (ClassFormatException e) {
|
|
|
a0c002 |
// treat as if class file is missing
|