Clang: Move printing functions in clang support to unit tests

The printing functions are only used by the unit tests and they use an
external API. So we can easily move them to the printing functions in
the unit test project. We have to move the TokenInfo print functions too
because the depend on other print functions. The rest of the print
functions will be moved in other patches.

Change-Id: I87c452f8ca40687ec47de675ba6bee13efa5655b
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
This commit is contained in:
Marco Bubke
2017-11-30 16:11:40 +01:00
parent 8cce4daa80
commit bb62fd3e56
106 changed files with 768 additions and 716 deletions

View File

@@ -27,8 +27,6 @@
#include <QDebug>
#include <ostream>
namespace ClangBackEnd {
namespace V2 {
@@ -43,17 +41,5 @@ QDebug operator<<(QDebug debug, const SourceLocationContainer &container)
return debug;
}
std::ostream &operator<<(std::ostream &os, const SourceLocationContainer &container)
{
os << "(("
<< container.filePathId().directoryId << ", " << container.filePathId().fileNameId << "), "
<< container.line() << ", "
<< container.column() << ", "
<< container.offset()
<< ")";
return os;
}
} // namespace V2
} // namespace ClangBackEnd