aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2012-02-26 16:55:50 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2012-02-26 16:55:50 +0000
commita6c10681e57c292e16a18bdb9891c8db6ebe5c83 (patch)
tree5294ebbe2087f147b67726fcd08da549a7d30701
parent5ed7dd6c8defe361a48209e4a04fbaebdd628bea (diff)
Move FullSourceLoc::dump into the .cpp file, the used attribute made us emit this into every TU that includes SourceLocation.h.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151493 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--include/clang/Basic/SourceLocation.h2
-rw-r--r--lib/Basic/SourceLocation.cpp4
2 files changed, 5 insertions, 1 deletions
diff --git a/include/clang/Basic/SourceLocation.h b/include/clang/Basic/SourceLocation.h
index c4a64e3d53..d5fa7e74ac 100644
--- a/include/clang/Basic/SourceLocation.h
+++ b/include/clang/Basic/SourceLocation.h
@@ -325,7 +325,7 @@ public:
/// Prints information about this FullSourceLoc to stderr. Useful for
/// debugging.
- LLVM_ATTRIBUTE_USED void dump() const { SourceLocation::dump(*SrcMgr); }
+ LLVM_ATTRIBUTE_USED void dump() const;
friend inline bool
operator==(const FullSourceLoc &LHS, const FullSourceLoc &RHS) {
diff --git a/lib/Basic/SourceLocation.cpp b/lib/Basic/SourceLocation.cpp
index 6e4f3e6ad7..bb5a10a9c7 100644
--- a/lib/Basic/SourceLocation.cpp
+++ b/lib/Basic/SourceLocation.cpp
@@ -115,6 +115,10 @@ bool FullSourceLoc::isBeforeInTranslationUnitThan(SourceLocation Loc) const {
return SrcMgr->isBeforeInTranslationUnit(*this, Loc);
}
+void FullSourceLoc::dump() const {
+ SourceLocation::dump(*SrcMgr);
+}
+
const char *FullSourceLoc::getCharacterData(bool *Invalid) const {
assert(isValid());
return SrcMgr->getCharacterData(*this, Invalid);