tree-sitter / tree-sitter-c

C grammar for tree-sitter

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

different highlight result of typedef

Freed-Wu opened this issue · comments

commented

Install nvim-treesitter, then vi /usr/include/linux/types.h:

screen-2023-10-01-20-26-02
Why __poll_t is not highlighted as __le16? Is it a bug?

Because __bitwise is a macro, expanding it parses fine, sorry tree-sitter isn't context aware to know that.

If you'd have posted the parse output, you can see clearly it fails:

image
commented

Hey, what is tsa in your screenshot?