From bda7dcb5c1d08f7a3d522988870c1d5f75697727 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Pl=C3=BCmicke?= Date: Thu, 11 Oct 2018 09:47:55 +0200 Subject: [PATCH] modified: src/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java --- src/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java b/src/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java index 3f9466cf..b1cbbe7b 100644 --- a/src/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java +++ b/src/de/dhbwstuttgart/typeinference/unify/TypeUnifyTask.java @@ -571,8 +571,9 @@ public class TypeUnifyTask extends RecursiveTask>> { if (!durchschnitt.isEmpty()) { UnifyPair groundBasepair = res.iterator().next().iterator().next().getGroundBasePair().get(); Set undefRes = res.stream().reduce((y,z) -> { y.addAll(z); return y;}).get(); - Set> reducedUndefResSubst = undefRes.stream() - .map(x -> x.getAllSubstitutions()).map(y -> { y.removeAll(durchschnitt); return y;}) + Set> reducedUndefResSubstGroundedBasePair = undefRes.stream() + .map(x -> { Set su = x.getAllSubstitutions(); su.add(x.getGroundBasePair().get()); return su;}) + .map(y -> { y.removeAll(durchschnitt); return y;}) .collect(Collectors.toCollection(HashSet::new)); Set resGroundBasepairs = undefRes.stream().map(x -> x.getGroundBasePair().get()).collect(Collectors.toCollection(HashSet::new)); if (res.size() > 1) {