From a24faf8f2defb43c2697611ba51235687eb47008 Mon Sep 17 00:00:00 2001 From: Andreas Stadelmeier Date: Tue, 17 May 2022 12:22:21 +0200 Subject: [PATCH] remove uncessary variable --- src/main/scala/hb/dhbw/Unify.scala | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/main/scala/hb/dhbw/Unify.scala b/src/main/scala/hb/dhbw/Unify.scala index 006071b..2de7e72 100644 --- a/src/main/scala/hb/dhbw/Unify.scala +++ b/src/main/scala/hb/dhbw/Unify.scala @@ -35,12 +35,11 @@ object Unify { } def subElimRule(eq: Set[UnifyConstraint]) : Option[Set[UnifyConstraint]] = { - var ret = eq eq.find(_ match{ case UnifyLessDot(UnifyTV(a), UnifyTV(b)) => true case _ => false }).map(it => { - subst(it.right.asInstanceOf[UnifyTV], it.left, ret.filter(it != _)) ++ Set(UnifyEqualsDot(it.right, it.left), UnifyEqualsDot(it.left, it.left)) + subst(it.right.asInstanceOf[UnifyTV], it.left, eq.filter(it != _)) ++ Set(UnifyEqualsDot(it.right, it.left), UnifyEqualsDot(it.left, it.left)) }) }