data: Extended CxxParser to detect elements
Detects most elements in the code, currently classes, structs, global variables, fields, functions, methods, namespaces and enums. The structs ParseLocation and ParseVariable are helper objects to transmit information to the ParserClient. Currently the parsed information only gets logged in the Storage. review id = 15 fortune cookie message = In dreams and in life, nothing is impossible.
This commit is contained in:
@@ -14,8 +14,10 @@ CxxParser::~CxxParser()
|
||||
|
||||
void CxxParser::parseFiles(const std::vector<std::string>& filePaths)
|
||||
{
|
||||
const char* argv[] = { "app", "--" };
|
||||
int argc = 2;
|
||||
// Fake commandline flags passed to the programm. Everything after '--' will be interpreted by the ClangTool.
|
||||
// The option '-x c++' treats subsequent input files as C++.
|
||||
const char* argv[] = { "app", "--", "-x", "c++" };
|
||||
int argc = 4;
|
||||
|
||||
std::shared_ptr<clang::tooling::FixedCompilationDatabase> compilationDatabase(
|
||||
clang::tooling::FixedCompilationDatabase::loadFromCommandLine(argc, argv)
|
||||
|
||||
Reference in New Issue
Block a user