[cfe-dev] Getting the class name for a category in libclang

David Chisnall csdavec at swan.ac.uk
Fri Oct 29 11:48:20 PDT 2010


Hi,

I'm trying to build an index using libclang, but there doesn't appear to be any way of getting the class name for a cursor representing an Objective-C category, other than to generate and then parse the USR.  Am I missing something, or is this missing functionality?  

If it's missing, does anyone have any thoughts about the correct way to expose this?  My initial expectation was that the semantic parent for a category should be the class, but there are a number of cases where this quickly becomes nonintuitive.  Should there be a dedicated function for getting the class name from a category declaration?

David

-- Sent from my Difference Engine







More information about the cfe-dev mailing list