forked from JavaTX/JavaCompilerCore
modified: src/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java
This commit is contained in:
parent
603c4c9c46
commit
fef4d27d21
@ -453,14 +453,15 @@ public class TypeUnifyTask extends RecursiveTask<Set<Set<UnifyPair>>> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (isUndefinedPairSetSet(result)) {
|
if (isUndefinedPairSetSet(result)) {
|
||||||
Set<UnifyPair> abhSubst = result.stream().findFirst()
|
Set<UnifyPair> abhSubst = result.stream()
|
||||||
.get()
|
.map(b ->
|
||||||
.stream()
|
b.stream()
|
||||||
.map(x -> x.getAllSubstitutions())
|
.map(x -> x.getAllSubstitutions())
|
||||||
|
.reduce((y,z) -> { y.addAll(z); return y;}).get())
|
||||||
.reduce((y,z) -> { y.addAll(z); return y;}).get();
|
.reduce((y,z) -> { y.addAll(z); return y;}).get();
|
||||||
Set<UnifyPair> durchschnitt = abhSubst.stream()
|
Set<UnifyPair> durchschnitt = abhSubst.stream()
|
||||||
.filter(x -> a.contains(x))
|
.filter(x -> a.contains(x))
|
||||||
.filter(y -> abhSubst.contains(y))
|
//.filter(y -> abhSubst.contains(y))
|
||||||
.collect(Collectors.toCollection(HashSet::new));
|
.collect(Collectors.toCollection(HashSet::new));
|
||||||
Set<PlaceholderType> vars = durchschnitt.stream().map(x -> (PlaceholderType)x.getLhsType()).collect(Collectors.toCollection(HashSet::new));
|
Set<PlaceholderType> vars = durchschnitt.stream().map(x -> (PlaceholderType)x.getLhsType()).collect(Collectors.toCollection(HashSet::new));
|
||||||
nextSetasList = nextSetasList.stream().filter(x -> {
|
nextSetasList = nextSetasList.stream().filter(x -> {
|
||||||
|
Loading…
Reference in New Issue
Block a user