[Mono-list] Why doesn't Mono include full stack trace information into exception?
Rodrigo Kumpera
kumpera at gmail.com
Tue Dec 31 01:47:00 UTC 2013
This is due to inlining. Run your program with -O=-inline and you'll get
what you want.
On Sun, Dec 29, 2013 at 11:16 PM, Andrei Faber <andrei.faber at gmail.com>wrote:
> Why doesn't Mono include full stack trace information into exception?
> For example, this code:
>
> class Program
> {
> static void Main(string[] args)
> {
> try
> {
> Foo();
> }
> catch (Exception exc)
> {
> Console.WriteLine(exc);
> }
> }
>
> static void Foo()
> {
> Bar();
> }
>
> static void Bar()
> {
> throw new ApplicationException();
> }
> }
>
> In MS .NET, it produces this output:
>
> System.ApplicationException: Error in the application.
> at ConsoleApplication2.Program.Bar()
> at ConsoleApplication2.Program.Foo()
> at ConsoleApplication2.Program.Main(String[] args)
>
> While in Mono:
>
> System.ApplicationException: An application exception has occurred.
> at ConsoleApplication2.Program.Main (System.String[] args) [0x00000] in
> <filename unknown>:0
>
> --
> Best wishes,
> Andrei Faber
>
> _______________________________________________
> Mono-list maillist - Mono-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ximian.com/pipermail/mono-list/attachments/20131230/d0d2e793/attachment.html>
More information about the Mono-list
mailing list