How to auto-re-compile with /debug option from inside DbgCLR.exe Debugger ?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Keith Clark

    How to auto-re-compile with /debug option from inside DbgCLR.exe Debugger ?

    When I load a csharp program into the MS DbgCLR.exe debugger and trace it everything is fine the first time.
    Assume now, I change somewhere a code statement in the source file (outside the Debug-IDE) without re-compiling it.

    DbgCLR.exe recognizes that something has changed in the source file and pops up a warning dialog asking if
    the new source should be used. If I click "yes" and re-start the debugging process from the beginning
    DbgCLR.exe displays then the new source BUT uses internally the old debugging information !!!

    In other words I need to re-compile the new source explicitely with a

    csc.exe /debug mysource.cs

    statement to update the mysource.pdb debug information as well.
    Hmmm, I could imagine that there is an option in the debug IDB DbgCLR.exe where I can enable an option

    "re-compile source with /debug flag before start".

    But I didn't found such an option in the settings.

    Do I really have to re-compile the source manually?
    Is tehre at least a setting which warns me if source (*.cs) and debug *.pdb file do not fit together ?

    Keith

  • Nicholas Paldino [.NET/C# MVP]

    #2
    Re: How to auto-re-compile with /debug option from inside DbgCLR.exe Debugger ?

    Keith,

    I don't believe that there is any such option. This would mean that the
    debugger would have to have knowledge of the type of code that it is, and
    know which compiler to invoke. This isn't to reasonable, IMO, and I would
    be surprized if something like that was there.

    Hope this helps.


    --
    - Nicholas Paldino [.NET/C# MVP]
    - mvp@spam.guard. caspershouse.co m

    "Keith Clark" <k.clark@lucent .com> wrote in message
    news:cg55lc$49b $01$1@news.t-online.com...[color=blue]
    > When I load a csharp program into the MS DbgCLR.exe debugger and trace it
    > everything is fine the first time.
    > Assume now, I change somewhere a code statement in the source file
    > (outside the Debug-IDE) without re-compiling it.
    >
    > DbgCLR.exe recognizes that something has changed in the source file and
    > pops up a warning dialog asking if
    > the new source should be used. If I click "yes" and re-start the debugging
    > process from the beginning
    > DbgCLR.exe displays then the new source BUT uses internally the old
    > debugging information !!!
    >
    > In other words I need to re-compile the new source explicitely with a
    >
    > csc.exe /debug mysource.cs
    >
    > statement to update the mysource.pdb debug information as well.
    > Hmmm, I could imagine that there is an option in the debug IDB DbgCLR.exe
    > where I can enable an option
    >
    > "re-compile source with /debug flag before start".
    >
    > But I didn't found such an option in the settings.
    >
    > Do I really have to re-compile the source manually?
    > Is tehre at least a setting which warns me if source (*.cs) and debug
    > *.pdb file do not fit together ?
    >
    > Keith
    >[/color]


    Comment

    Working...