Use isFromMainFile instead of comparing FileIDs directly.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49687 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Driver/RewriteTest.cpp b/Driver/RewriteTest.cpp
index 55c5f1a..1c54c5a 100644
--- a/Driver/RewriteTest.cpp
+++ b/Driver/RewriteTest.cpp
@@ -384,7 +384,7 @@
RewriteForwardProtocolDecl(FP);
}
// If we have a decl in the main file, see if we should rewrite it.
- if (SM->getDecomposedFileLoc(Loc).first == MainFileID)
+ if (SM->isFromMainFile(Loc))
return HandleDeclInMainFile(D);
}