大家好,我刚刚在我的 Mac Snow Leopard OSX 上安装了:
Mono 2.6 和 Monodevelop 2.2
我创建了一个简单的 C# 控制台应用程序:
public static void Main (string[] args)
{
Console.WriteLine ("Hello World!");
Console.Read();
}
当我开始输入“Console”时,智能感知完美运行。
当我在 Debug模式下运行应用程序时,断点按预期命中。
但是,在使用断点进行调试时,如果我将鼠标悬停在“控制台”上,它会显示“未知标识符”
当我尝试使用即时窗口时,没有任何效果。我输入的任何内容都只会显示“未知标识符”。
有人知道这是怎么回事吗?
干杯!
最佳答案
试试这个并使用 -debug 标志进行编译:
public static int Main (string[] args)
{
Console.WriteLine ("Hello World!");
Console.Read();
return 0; // Place breakpoint here
}
如果可行,那么试试这个:
public static void Main (string[] args)
{
int dummy;
Console.WriteLine ("Hello World!"); // Place breakpoint here
Console.Read();
}
关于macos - 在 OSX 上的 Monodevelop 中调试不太有效,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1974123/