summaryrefslogtreecommitdiff
path: root/compilerplugins/clang/convertlong.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'compilerplugins/clang/convertlong.cxx')
-rw-r--r--compilerplugins/clang/convertlong.cxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/compilerplugins/clang/convertlong.cxx b/compilerplugins/clang/convertlong.cxx
index b706d7dffaa4..8038b8a6371b 100644
--- a/compilerplugins/clang/convertlong.cxx
+++ b/compilerplugins/clang/convertlong.cxx
@@ -35,9 +35,7 @@ public:
virtual void run() override
{
- std::string fn(compiler.getSourceManager()
- .getFileEntryForID(compiler.getSourceManager().getMainFileID())
- ->getName());
+ std::string fn(handler.getMainFileName());
loplugin::normalizeDotDotInFilePath(fn);
// using sal_uIntPtr as in-between type when converting void* to rtl_TextEncoding
if (fn == SRCDIR "/sal/osl/unx/thread.cxx")
@@ -74,7 +72,7 @@ bool ConvertLong::VisitVarDecl(VarDecl const* varDecl)
{
if (ignoreLocation(varDecl))
return true;
- StringRef fileName{ compiler.getSourceManager().getFilename(varDecl->getLocation()) };
+ StringRef fileName{ getFileNameOfSpellingLoc(varDecl->getLocation()) };
if (loplugin::isSamePathname(fileName, SRCDIR "/include/tools/bigint.hxx"))
return true;
if (loplugin::isSamePathname(fileName, SRCDIR "/include/tools/solar.h"))