[Mono-bugs] [Bug 58288][Nor] Changed - System.Diagnostics.StackTrace never provides file/line info

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Tue, 11 May 2004 11:42:57 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by shaver@off.net.

http://bugzilla.ximian.com/show_bug.cgi?id=58288

--- shadow/58288	2004-05-11 11:31:46.000000000 -0400
+++ shadow/58288.tmp.20968	2004-05-11 11:42:57.000000000 -0400
@@ -1,13 +1,13 @@
 Bug#: 58288
 Product: Mono: Runtime
 Version: unspecified
 OS: unknown
 OS Details: FC2T3, x86 (+updates)
-Status: NEW   
-Resolution: 
+Status: RESOLVED   
+Resolution: INVALID
 Severity: Unknown
 Priority: Normal
 Component: misc
 AssignedTo: mono-bugs@ximian.com                            
 ReportedBy: shaver@off.net               
 QAContact: mono-bugs@ximian.com
@@ -40,6 +40,23 @@
         at Test.Main()
  
 and that's all, so they're even more broken. (?)
 
 I don't know what the --debug equivalent is, though, so maybe that has
 an effect.
+
+------- Additional Comments From shaver@off.net  2004-05-11 11:42 -------
+*sigh*.
+
+If I explicitly ask for the file/line info, I get it:
+
+    static void C() {
+        StackTrace trace = new StackTrace(true);
+        for (int i = 0; i < trace.FrameCount; i++) {
+            StackFrame sf = trace.GetFrame(i);
+            Console.WriteLine("{0}@{1}:{2}",
+                              sf.GetMethod(), sf.GetFileName(),
+                              sf.GetFileLineNumber());
+        }
+    }
+
+Sorry.