此浏览器不再受支持。
请升级到 Microsoft Edge 以使用最新的功能、安全更新和技术支持。
更新:2007 年 11 月
关键字“void”不能用于此上下文中
编译器检测到无效的 void 关键字使用。
下面的示例生成 CS1547:
// CS1547.cs public class MyClass { void BadMethod() { void i; // CS1547, cannot have variables of type void } public static void Main() { } }