[Mono-bugs] [Bug 434822] FEATURE: Cannot set breakpoint on method declaration line

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Wed Aug 19 14:32:47 EDT 2009


http://bugzilla.novell.com/show_bug.cgi?id=434822

User martin at novell.com added comment
http://bugzilla.novell.com/show_bug.cgi?id=434822#c9





--- Comment #9 from Martin Baulig <martin at novell.com>  2009-08-19 12:32:46 MDT ---
The problem here is the following:

csc does not emit any symbol information into the .pdb file for the method
declaration line.

This is a problem because the method declaration "line" could in fact span
multiple lines - this is also quite common if the method has a lot of
arguments, people often write code like this:

======
5      .... // some method
6   }
7
8   void
9   ISomeInterface.ExplicitlyImplementedMethod (SomeClass.Type a,
10                                              string b,
11                                              float c)
12  {
13     .... // method body
14  }
======

Here, according to the pdb, the method spans from line 12 to line 14 - but I'd
need to deal with lines 8-11 somehow, and what about line 7 ?

There is one little trick:

Visual Studio doesn't allow you to insert breakpoints on invalid lines, so you
can't actually have a breakpoint on line 7.

This means I could probably treat all the free space between two methods as
belonging to the next method.  However, this needs to be tested with #line
directives and compiler-generated code.

I've also no idea how to "move" the breakpoint to line 12 at run-time.

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list