aboutsummaryrefslogtreecommitdiff
path: root/Driver/RewriteTest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Driver/RewriteTest.cpp')
-rw-r--r--Driver/RewriteTest.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Driver/RewriteTest.cpp b/Driver/RewriteTest.cpp
index 55c5f1a142..1c54c5a81d 100644
--- a/Driver/RewriteTest.cpp
+++ b/Driver/RewriteTest.cpp
@@ -384,7 +384,7 @@ void RewriteTest::HandleTopLevelDecl(Decl *D) {
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);
}