Hi Víctor, On Mon, Jul 4, 2022 at 3:18 PM Víctor Colombo <victor.colo...@eldorado.org.br> wrote: > And I receive an exception on the line above saying that node is of type > NoneType. Seems that `node = node.referenced` is setting `node` to None > in this case. > > I was unable to understand the root cause of it. Is this an incorrect > usage of the tool from my part? Full error message below
Unfortunately there seem to be a lot of corner cases that libclang can throw at us. I hadn't come across this one before. I expected that DECL_REF_EXPR/MEMBER_REF_EXPR would always reference something. This may be due to some build error -- libclang tries to continue processing a translation unit by dropping subtrees or nodes that have problems. Is there a "too many errors emitted, stopping now; this may lead to false positives and negatives" line at the top of the script's output? Thanks, Alberto