更新:2007 年 11 月
错误消息
应输入单行注释或行尾带有
下面的示例生成 CS1025:
#if true /* hello */ // CS1025 #endif // this is a good comment  | |
如果尝试使用某些无效的预处理器指令,则也可能发生 CS1025,如下所示:
// CS1025.cs
#define a
class Sample
{
   static void Main()
   {
      #if a 1   // CS1025, invalid syntax
         System.Console.WriteLine("Hello, World!");
      #endif
   }
} | |