[Mono-devel-list] Line numbers in stacktraces are off by one
atsushi at ximian.com
Tue Jun 7 05:03:34 EDT 2005
I was (well, I should say "am") working on that matter (aka
precise location patch) but currently it is not done yet.
I created mcs patch 6 months ago and mcs has greatly improved,
it is not impossible to merge directly (and not successful).
I hope I can fix the patch and repost again in the near future.
Hans Kratz wrote:
> I just implemented support for hyperlinking Mono exception stacktraces
> in X-develop and noticed that line numbers in stacktraces are off by one.
> E.g. for the following program...
> class Program
> static void Main(string args)
> string s = null;
> int i = s.Length; // line 6
> } // line 7
> ... I get this stacktrace....
> $ mono --debug ConsoleApplication45.exe
> Unhandled Exception: System.NullReferenceException: Object reference not
> set to an instance of an object
> in [0x00003] (at /home/hans/[...]/Program.cs:7) Program:Main
> (System.String args)
> Is this intentional?
> Best regards,
More information about the Mono-devel-list