分享方式:


嚴重錯誤 C1019

未預期的 #else

#else 指示詞出現在 #if#ifdef#ifndef 建構外部。 請僅在其中一個建構內使用 #else

下列範例會產生 C1019:

// C1019.cpp
#else   // C1019
#endif

int main() {}

可能的解決方式:

// C1019b.cpp
#if 1
#else
#endif

int main() {}