using the compiler's method lookup from a clang plugin?


I have two
const clang::RecordType * t1, t2
and I want to find out if there exits an
that can be called with those two types.

I’ve partially implemented this in my plugin, but it gets complicated quickly, and surely the compiler already does this?

Any suggestions where to look to invoke such functionality?

Thanks, Noel Grandin

It looks like

void Sema::LookupOverloadedOperatorName(OverloadedOperatorKind Op, Scope *S,
QualType T1, QualType T2,
UnresolvedSetImpl &Functions)

is the chunk of functionality I need, but how do I call that from a RecursiveASTVisitor plugin?

In particular, how do I get a pointer to a Scope?

Thanks, Noel Grandin