更新:2007 年 11 月
错误消息
检测到无法访问的代码
编译器检测到永远不执行的代码。
下面的示例生成 CS0162:
// CS0162.cs
// compile with: /W:2
public class A
{
   public static void Main()
   {
      goto lab1;
      {
         // The following statements cannot be reached:
         int i = 9;   // CS0162 
         i++;
      }
      lab1:
      {
      }
   }
}