diff options
-rw-r--r-- | compilerplugins/clang/externandnotdefined.cxx | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/compilerplugins/clang/externandnotdefined.cxx b/compilerplugins/clang/externandnotdefined.cxx index e66247fa1fad..2deca8adadcf 100644 --- a/compilerplugins/clang/externandnotdefined.cxx +++ b/compilerplugins/clang/externandnotdefined.cxx @@ -54,8 +54,7 @@ bool ExternAndNotDefined::VisitFunctionDecl(const FunctionDecl * functionDecl) { if (functionName == "gdk_x11_screen_get_screen_number") { return true; } - SourceLocation spellingLocation = compiler.getSourceManager().getSpellingLoc(functionDecl->getLocation()); - if (!compat::isInMainFile( compiler.getSourceManager(), spellingLocation)) { + if (!compat::isInMainFile( compiler.getSourceManager(), functionDecl->getLocation())) { return true; } StringRef fileName { compiler.getSourceManager().getFilename(functionDecl->getLocation()) }; |