Skip to content

naclsn/tree-sitter-nasm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

44 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tree-sitter-nasm

NASM grammars with tree-sitter.

References


Notes/Remarks

  • an expression is an expression (e.g. no "critical expressions")
  • macro reserved token are always allowed (e.g. %0) same with $ and $$
  • handling of e.g. struc and align standard macros (even though they are just macros)
  • things like j%-1 will fail (maybe (instruction j (operand %+1)) or whatever)
  • the fact that ':' is optional after a label makes it inherently ambigus:
_start:
	word1	word2
	; 'word1' may be a macro or the label and
	; 'word2' the instruction or an operand

Here opts for 'word1' as an instruction (and thus 'word2' as its first operand).

Releases

No releases published

Packages

No packages published

Languages