|
|
|
@ -133,7 +133,6 @@ namespace ICSharpCode.Decompiler.IL.Transforms
@@ -133,7 +133,6 @@ namespace ICSharpCode.Decompiler.IL.Transforms
|
|
|
|
|
} |
|
|
|
|
foreach (var transform in children) |
|
|
|
|
{ |
|
|
|
|
Debug.Assert(block.HasFlag(InstructionFlags.EndPointUnreachable)); |
|
|
|
|
transform.Run(block, pos, ctx); |
|
|
|
|
#if DEBUG
|
|
|
|
|
block.Instructions[pos].CheckInvariant(ILPhase.Normal); |
|
|
|
@ -160,6 +159,10 @@ namespace ICSharpCode.Decompiler.IL.Transforms
@@ -160,6 +159,10 @@ namespace ICSharpCode.Decompiler.IL.Transforms
|
|
|
|
|
pos--; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
// This invariant can be surprisingly expensive to check if the block has thousands
|
|
|
|
|
// of instructions and is frequently modified by transforms (invalidating the flags each time)
|
|
|
|
|
// so we'll check this only once at the end of the block.
|
|
|
|
|
Debug.Assert(block.HasFlag(InstructionFlags.EndPointUnreachable)); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|