diff options
Diffstat (limited to 'Source/Core/DeadVarElim.cs')
-rw-r--r-- | Source/Core/DeadVarElim.cs | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/Source/Core/DeadVarElim.cs b/Source/Core/DeadVarElim.cs index e9975fe5..2993feb7 100644 --- a/Source/Core/DeadVarElim.cs +++ b/Source/Core/DeadVarElim.cs @@ -421,14 +421,13 @@ namespace Microsoft.Boogie { foreach (Block/*!*/ block in sortedNodes) {
Contract.Assert(block != null);
HashSet<Variable/*!*/>/*!*/ liveVarsAfter = new HashSet<Variable/*!*/>();
- if (impl.InjectedAssumptionVariables != null)
+
+ // The injected assumption variables should always be considered to be live.
+ foreach (var v in impl.InjectedAssumptionVariables)
{
- // The injected assumption variables should always be considered to be live.
- foreach (var v in impl.InjectedAssumptionVariables)
- {
- liveVarsAfter.Add(v);
- }
+ liveVarsAfter.Add(v);
}
+
if (block.TransferCmd is GotoCmd) {
GotoCmd gotoCmd = (GotoCmd)block.TransferCmd;
if (gotoCmd.labelTargets != null) {
|