[Mono-bugs] [Bug 549722] New: The debugger doesn't stop on the first line of the Main method in a console application

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Fri Oct 23 15:33:09 EDT 2009


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


           Summary: The debugger doesn't stop on the first line of the
                    Main method in a console application
    Classification: Mono
           Product: Mono: Tools
           Version: MonoVS 0.7
          Platform: i586
        OS/Version: openSUSE 11.1
            Status: NEW
          Severity: Major
          Priority: P5 - None
         Component: Visual Studio Integration
        AssignedTo: martin at novell.com
        ReportedBy: twiest at novell.com
         QAContact: mono-bugs at lists.ximian.com
          Found By: Community User


Description of Problem:
The debugger doesn't stop on the first line of the Main method in a console
application.

If you set it on a line further down, then it properly stops on the break
point. It doesn't seem to matter what the first line is. I've tried to stop on
the first line when it's a Console.WriteLine, as well as when it's a variable
declaration. Neither stopped on the break point.

This was found in MonoVS 0.7 on WinXP i586 and the MonoVS 0.7 VM (openSUSE 11.1
i586).

This was originally reported by Rob Kean on the mono-vsbeta mailing list.


Steps to reproduce the problem:
1. Create a new solution based on the C# console template project.
2. Add this to the Main method:
            Console.WriteLine("testing...");
            Console.ReadLine();
3. Set a break point on the Console.WriteLine line.
4. On the Linux side, make sure "Run in terminal" is checked.
5. Click "Mono / Debug Remotely in Mono"
6. Notice that Visual studio doesn't stop on the break point.


However, this works:
1. Create a new solution based on the C# console template project.
2. Add this to the Main method:
            Console.Write("What is your name? ");
            string name = Console.ReadLine();
            Console.WriteLine("You said: " + name);
3. Set a break point on the *2nd* Console.WriteLine line.
4. On the Linux side, make sure "Run in terminal" is checked.
5. Click "Mono / Debug Remotely in Mono"


Actual Results:
VS doesn't stop on the break point.


Expected Results:
It should stop on the break point.


How often does this happen? 
every 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