A tree-sitter grammar for x86 assembly, Intel syntax.
Just enough to highlight stuff on https://fasterthanli.me/.
In particular:
- Parsing of effective addresses is very hacky (but highlights fine)
- NASM macros aren't parsed at all
- A ton of stuff is missing
But still, it makes a bunch of code look good, and that's good enough for me.
It even sorta-understands objdump output:
This project is primarily distributed under the terms of both the MIT license and the Apache License (Version 2.0).
See LICENSE-APACHE and LICENSE-MIT for details.