diff options
| -rw-r--r-- | clang/lib/AST/Decl.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/AST/Decl.cpp b/clang/lib/AST/Decl.cpp index 1e98998002f..ec11838c847 100644 --- a/clang/lib/AST/Decl.cpp +++ b/clang/lib/AST/Decl.cpp @@ -1478,7 +1478,7 @@ bool FunctionDecl::isMain() const { const TranslationUnitDecl *tunit = dyn_cast<TranslationUnitDecl>(getDeclContext()->getRedeclContext()); return tunit && - tunit->getASTContext().getLangOptions().Freestanding && + !tunit->getASTContext().getLangOptions().Freestanding && getIdentifier() && getIdentifier()->isStr("main"); } |

