src: fixed crashes on parsing Coati
* also fixed log path getting messed up by indexing a project using a CDB
This commit is contained in:
@@ -66,28 +66,23 @@ bool CxxVerboseAstVisitor::TraverseStmt(clang::Stmt *stmt)
|
||||
return true;
|
||||
}
|
||||
|
||||
bool CxxVerboseAstVisitor::TraverseType(clang::QualType t)
|
||||
{
|
||||
LOG_INFO_STREAM_BARE(<< "Indexer - " << getIndentString() << t->getTypeClassName() << "Type");
|
||||
{
|
||||
ScopedSwitcher<unsigned int> switcher(m_indentation, m_indentation + 1);
|
||||
return base::TraverseType(t);
|
||||
}
|
||||
}
|
||||
|
||||
bool CxxVerboseAstVisitor::TraverseTypeLoc(clang::TypeLoc tl)
|
||||
{
|
||||
ParseLocation loc = getParseLocation(tl.getSourceRange());
|
||||
LOG_INFO_STREAM_BARE(
|
||||
<< "Indexer - "
|
||||
<< getIndentString() << typeLocClassToString(tl)
|
||||
<< "TypeLoc <" << loc.startLineNumber << ":" << loc.startColumnNumber
|
||||
<< ", " << loc.endLineNumber << ":" << loc.endColumnNumber << ">"
|
||||
);
|
||||
if (!tl.isNull())
|
||||
{
|
||||
ScopedSwitcher<unsigned int> switcher(m_indentation, m_indentation + 1);
|
||||
return base::TraverseTypeLoc(tl);
|
||||
ParseLocation loc = getParseLocation(tl.getSourceRange());
|
||||
LOG_WARNING_STREAM_BARE(
|
||||
<< "Indexer - "
|
||||
<< getIndentString() << typeLocClassToString(tl)
|
||||
<< "TypeLoc <" << loc.startLineNumber << ":" << loc.startColumnNumber
|
||||
<< ", " << loc.endLineNumber << ":" << loc.endColumnNumber << ">"
|
||||
);
|
||||
{
|
||||
ScopedSwitcher<unsigned int> switcher(m_indentation, m_indentation + 1);
|
||||
return base::TraverseTypeLoc(tl);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
std::string CxxVerboseAstVisitor::getIndentString() const
|
||||
|
||||
Reference in New Issue
Block a user