From 20a60f7d01449b9763dee1e00944e6839fb3b3e1 Mon Sep 17 00:00:00 2001 From: jjenista Date: Thu, 21 Aug 2008 23:56:52 +0000 Subject: [PATCH] use unionUpArity in simple rewrite scenario also --- Robust/src/Analysis/OwnershipAnalysis/TokenTupleSet.java | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Robust/src/Analysis/OwnershipAnalysis/TokenTupleSet.java b/Robust/src/Analysis/OwnershipAnalysis/TokenTupleSet.java index 51e21242..c3acc46b 100644 --- a/Robust/src/Analysis/OwnershipAnalysis/TokenTupleSet.java +++ b/Robust/src/Analysis/OwnershipAnalysis/TokenTupleSet.java @@ -223,15 +223,13 @@ public class TokenTupleSet extends Canonical { Iterator replaceItr = replacements.iterator(); while( replaceItr.hasNext() ) { TokenTupleSet replacement = replaceItr.next(); - TokenTupleSet replaced = new TokenTupleSet(); - replaced.tokenTuples.addAll( ttsMinusToken.tokenTuples ); - replaced.tokenTuples.addAll( replacement.tokenTuples ); - replaced = replaced.makeCanonical(); + TokenTupleSet replaced = new TokenTupleSet( ttsMinusToken ); + replaced = replaced.unionUpArity( replacement ); rsOut = rsOut.add( replaced ); } } - return rsOut; + return rsOut.makeCanonical(); } -- 2.34.1