How to find out whether a member function is const or volatile with libclang?

Viewed 2236

I have an instance of CXCursor of kind CXCursor_CXXMethod. I want to find out if the function is const or volatile, for example:

class Foo {
public:
    void bar() const;
    void baz() volatile;
    void qux() const volatile;
};

I could not find anything useful in the documentation of libclang. I tried clang_isConstQualifiedType and clang_isVolatileQualifiedType but these always seem to return 0 on C++ member function types.

1 Answers
Related