Browse Source
git-svn-id: svn://svn.sharpdevelop.net/sharpdevelop/branches/2.0@1268 1ccf3a8d-04fe-1044-b7c0-cef0b8235c61shortcuts
5 changed files with 148 additions and 66 deletions
@ -0,0 +1,40 @@ |
|||||||
|
// <file>
|
||||||
|
// <copyright see="prj:///doc/copyright.txt"/>
|
||||||
|
// <license see="prj:///doc/license.txt"/>
|
||||||
|
// <owner name="David Srbecký" email="dsrbecky@gmail.com"/>
|
||||||
|
// <version>$Revision$</version>
|
||||||
|
// </file>
|
||||||
|
|
||||||
|
namespace Debugger.Wrappers.CorDebug |
||||||
|
{ |
||||||
|
using System; |
||||||
|
using System.Collections.Generic; |
||||||
|
|
||||||
|
|
||||||
|
public partial class ICorDebugChainEnum |
||||||
|
{ |
||||||
|
public IEnumerable<ICorDebugChain> Enumerator { |
||||||
|
get { |
||||||
|
while (true) { |
||||||
|
ICorDebugChain corChain = Next(); |
||||||
|
if (corChain != null) { |
||||||
|
yield return corChain; |
||||||
|
} else { |
||||||
|
break; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public ICorDebugChain Next() |
||||||
|
{ |
||||||
|
ICorDebugChain[] corChains = new ICorDebugChain[1]; |
||||||
|
uint chainsFetched = this.Next(1, corChains); |
||||||
|
if (chainsFetched == 0) { |
||||||
|
return null; |
||||||
|
} else { |
||||||
|
return corChains[0]; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
@ -0,0 +1,40 @@ |
|||||||
|
// <file>
|
||||||
|
// <copyright see="prj:///doc/copyright.txt"/>
|
||||||
|
// <license see="prj:///doc/license.txt"/>
|
||||||
|
// <owner name="David Srbecký" email="dsrbecky@gmail.com"/>
|
||||||
|
// <version>$Revision$</version>
|
||||||
|
// </file>
|
||||||
|
|
||||||
|
namespace Debugger.Wrappers.CorDebug |
||||||
|
{ |
||||||
|
using System; |
||||||
|
using System.Collections.Generic; |
||||||
|
|
||||||
|
|
||||||
|
public partial class ICorDebugFrameEnum |
||||||
|
{ |
||||||
|
public IEnumerable<ICorDebugFrame> Enumerator { |
||||||
|
get { |
||||||
|
while (true) { |
||||||
|
ICorDebugFrame corFrame = Next(); |
||||||
|
if (corFrame != null) { |
||||||
|
yield return corFrame; |
||||||
|
} else { |
||||||
|
break; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
|
||||||
|
public ICorDebugFrame Next() |
||||||
|
{ |
||||||
|
ICorDebugFrame[] corFrames = new ICorDebugFrame[1]; |
||||||
|
uint framesFetched = this.Next(1, corFrames); |
||||||
|
if (framesFetched == 0) { |
||||||
|
return null; |
||||||
|
} else { |
||||||
|
return corFrames[0]; |
||||||
|
} |
||||||
|
} |
||||||
|
} |
||||||
|
} |
Loading…
Reference in new issue