When you have an assembly aspect that changes the code of a method, and this code fails (or shows a failed assert), the debugger shows the aspect as current code line.
Example source code:
[assembly: MyAspect] method MyMethod; begin //some code end;
The aspect MyAspect changes the code of MyMethod to:
method MyMethod; begin System.Diagnostics.Debug.Assert(false, 'the error'); //inserted by the aspect, not in the source code //some code end;
When MyMethod is executed, the assert is shown, but the debugger breaks on the line:
instead of (what should be more logical for debugging) on the line
Is it possible to change this behavior?