Hello all,
I want to get an enhanced classView tree, which contains not only the hierarchy 
of projects, namespaces, classes and its members, but also the local variables 
of each function. How can I extract them? I have checked the functions in the 
ClassView::Internal::Parser and found that in its function addSymbol() all 
symbols with qualified name is ignored:

    const CPlusPlus::Name *symbolName = symbol->name();
    if (symbolName && symbolName->isQualifiedNameId() )
        return;

That is to say, all symbols in function bodys are unchecked, because member 
functions defined in .cpp file must have prefix like [Class Name]::, which is 
called qualified name in creator's source code.

I tried to cancel this, then all variables in functions are exposed, but in the 
classView tree, the function's node is not merged to its declaration node. That 
is, there are two separated nodes for one function, one is its declaration in 
the .h file, the other is its implementation in the .cpp file.

Then I tried to merge this two nodes, I found that in getParseProjectTree() 
each document's symbol tree will be merged.  But that didn't work because the 
scope hierarchy in cpp file can be incompleted. For example, when one declare 
using namespace A, then there's no need to write namespace A{ void 
classA::funA(){...}}, but write void classA::funA(){...} directly.

So how can I make the scope hierarchy completed in order to merge the function 
node? 

Best regards,
dydx
_______________________________________________
Qt-creator mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/qt-creator

Reply via email to