From: Vedant Kumar Date: Fri, 12 Aug 2016 00:20:39 +0000 (+0000) Subject: [Basic] Add const qualifier to SM.isInSystemMacro (NFC) X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=268e1ac4d54e82e75447b188958f99951f2257dd;p=clang [Basic] Add const qualifier to SM.isInSystemMacro (NFC) The member function is a predicate, and doesn't apply any changes on the object. Patch by Visoiu Mistrih Francis! Differential Revision: https://reviews.llvm.org/D23433 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@278444 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/clang/Basic/SourceManager.h b/include/clang/Basic/SourceManager.h index e00c99e4ad..6610c56b15 100644 --- a/include/clang/Basic/SourceManager.h +++ b/include/clang/Basic/SourceManager.h @@ -1357,7 +1357,7 @@ public: } /// \brief Returns whether \p Loc is expanded from a macro in a system header. - bool isInSystemMacro(SourceLocation loc) { + bool isInSystemMacro(SourceLocation loc) const { return loc.isMacroID() && isInSystemHeader(getSpellingLoc(loc)); }