I'm seeing some weird behaviour debugging my C# code - I cant post my exact code but essentially I have a partial abstract base class that defines an Execute method:
public abstract partial class MyBase
{
public abstract void Execute();
protect static object SomeMethod()
{
object aaa = OtherClass.GetObject();
// etc...
}
}
I then have another partial class which implements this method, and calls some static methods on the base class:
partial abstract class MyParent : MyBase
{
public void Execute()
{
object myobj = SomeMethod();
// etc...
}
}
Both of these partial classes have are extensions of partial classes generated using xsd.exe from a schema.
What I'm seeing is that if I attempt to step-into my implementation of Execute(), the Visual Stuido debugger jumps through these methods - for example in this case it would step straight through to the OtherClass.GetObject()
method. The call stack still shows all the frames inbetween Execute()
and OtherClass.GetObject()
, and even lets me set them to be the active frame, however I can't do a line-by-line step through the code unless I place a breakpoint on each and every line.
- Why is this?
- How can I fix it so I can debug normally again!?