0

When using clang::ParseAST on this code only (no more, no less)

class A : public B, public C 
{
    int field;
};

I'm not able to get informations about B and C, they seem completely ignored and are not present when looping with

CXXRecordDecl::bases_begin() / CXXRecordDecl::bases_end() 

Can I find informations about these base declarations somewhere, even if they are obviously 'undefined symbols' ?

Juicebox
  • 442
  • 4
  • 11
  • 1
    An educated guess: Over the `ASTContext::getDiagnostics()` member function you can get hold of a reference to a `DiagnosticsEngine` which has a member function to set a `DiagnosticsConsumer` (http://clang.llvm.org/doxygen/classclang_1_1DiagnosticConsumer.html) which looks a lot like what you're searching for. – Daniel Jour Mar 16 '16 at 01:11
  • Thanks for this, i think i will take a look to this option ! But i would like to know if any Decl is not accessible somewhere for each of these B and C classes (something that would look like "InvalidDecl" or else...) – Juicebox Mar 16 '16 at 01:22

0 Answers0