From 3bbfa221287317ea298b5795394368f2ea12e61b Mon Sep 17 00:00:00 2001 From: mterwoord_cp <7cd3fd84a0151ea055c2f79e4d2eef9576fe9afesxUZAwxD> Date: Wed, 11 Aug 2010 13:09:08 +0000 Subject: [PATCH] --- .../IL2PCU/Cosmos.IL2CPU.X86/AppAssemblerNasm.cs | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/source2/IL2PCU/Cosmos.IL2CPU.X86/AppAssemblerNasm.cs b/source2/IL2PCU/Cosmos.IL2CPU.X86/AppAssemblerNasm.cs index 6234796f9..d97c88bd8 100644 --- a/source2/IL2PCU/Cosmos.IL2CPU.X86/AppAssemblerNasm.cs +++ b/source2/IL2PCU/Cosmos.IL2CPU.X86/AppAssemblerNasm.cs @@ -73,12 +73,12 @@ namespace Cosmos.IL2CPU.X86 { xCodeOffsets = new int[xSmbMethod.SequencePointCount]; var xCodeDocuments = new ISymbolDocument[xSmbMethod.SequencePointCount]; - var xCodeLines = new int[xSmbMethod.SequencePointCount]; + xCodeLineNumbers = new int[xSmbMethod.SequencePointCount]; var xCodeColumns = new int[xSmbMethod.SequencePointCount]; var xCodeEndLines = new int[xSmbMethod.SequencePointCount]; var xCodeEndColumns = new int[xSmbMethod.SequencePointCount]; xSmbMethod.GetSequencePoints(xCodeOffsets, xCodeDocuments - , xCodeLines, xCodeColumns, xCodeEndLines, xCodeEndColumns); + , xCodeLineNumbers, xCodeColumns, xCodeEndLines, xCodeEndColumns); } } } @@ -346,7 +346,13 @@ namespace Cosmos.IL2CPU.X86 // If the current position equals one of the offsets, then we have // reached a new atomic C# statement if (aCodeOffsets != null) { - if (aCodeOffsets.Contains(aOp.Position) == false) { + var xIndex = Array.IndexOf(aCodeOffsets, aOp.Position); + if (xIndex == -1) { + return; + } + // 0xFEEFEE means hiddenline -> we dont want to stop there + if (xCodeLineNumbers[xIndex] == 0xFEEFEE) + { return; } } @@ -396,6 +402,7 @@ namespace Cosmos.IL2CPU.X86 } private int[] xCodeOffsets; + private int[] xCodeLineNumbers; protected override void AfterOp(MethodInfo aMethod, ILOpCode aOpCode) { base.AfterOp(aMethod, aOpCode); var xContents = "";