Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] How to get the IASTName from an IIndexName ?



On Thu, May 21, 2009 at 9:52 PM, manivannan_pk <manivannanp_k@xxxxxxxxxxx> wrote:


The method IIndex.findNames(binding, option) returns an array of
IIndexName-s. How do we get the IASTName corresponding to an IIndexName ?

IASTName makes sense only in a context of IASTTranslationUnit.

IASTTranslationUnit.getDefinitions(IBinding) 
IASTTranslationUnit.getDeclarations(IBinding) (declarations also include definitions)
IASTTranslationUnit.getReferences(IBinding) 

return IASTNames for the names in the AST and IIndexName for the names outside.



Moreover, the IIndex doc says that the interface is EXPERIMENTAL. Is there
any other well-tested stable way to find all the references to an IBinding
in the workspace ? (Searching for references in all the ITranslationUnit-s
one by one is not efficient.)

IASTTranslationUnit is not experimental. 


Thanks,
mani

-sergey 


--
View this message in context: http://www.nabble.com/How-to-get-the-IASTName-from-an-IIndexName---tp23664378p23664378.html
Sent from the Eclipse CDT - Development mailing list archive at Nabble.com.

_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/cdt-dev


Back to the top