[cfe-dev] Unable to AST Match on Subclasses of TypeLoc

scott constable via cfe-dev cfe-dev at lists.llvm.org
Thu Jul 27 12:48:24 PDT 2017


Hi All,

I can't seem to get any of:
pointeeLoc()
hasElementTypeLoc()
hasValueTypeLoc()
to compile. For instance,

TypeLocMatcher M = pointeeLoc(loc(pointerType()));

fails to compile with the error "no member named 'getPointeeLoc' in
'clang::TypeLoc'. Moreover, it seems I cannot write my own AST matchers
which return subclasses of TypeLoc.
ast_type_traits::DynTypedNode::BaseCoverter appears to be undefined for
subclasses of TypeLoc.

Any help would be much appreciated.

Thanks,

Scott Constable
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20170727/7f103763/attachment.html>


More information about the cfe-dev mailing list