public void join(ICollection <Tuple <BasicEdge.Guard, SubexpressionCounter> > predecessors, StatementId si) { subexpressionCounts = new Dictionary <string, SubExpression>(); currentStatement = si; // HashSet<string> ses = new HashSet<string>(); if (predecessors.Count == 1 && predecessors.First().Item2.currentStatement.predecessors.Count == 1) { subexpressionCounts = predecessors.First().Item2.subexpressionCounts; } else { foreach (var p in predecessors) { foreach (var v in p.Item2.subexpressionCounts) { SubExpression se = null; if (!subexpressionCounts.TryGetValue(v.Key, out se)) { subexpressionCounts.Add(v.Key, new SubExpression(v.Value)); // Debug.Assert(v.Key == subexpressionCounts[v.Key].fae.ToString()); } else { se.merge(currentStatement, v.Value); // Debug.Assert(v.Key == subexpressionCounts[v.Key].fae.ToString()); } } } } // currentStatement = null; }