ChimeHQ / SwiftTreeSitter

Swift API for the tree-sitter incremental parsing system
BSD 3-Clause "New" or "Revised" License
271 stars 30 forks source link

export tree sitter's id field #28

Closed lijunsong closed 5 months ago

lijunsong commented 5 months ago

This PR exports the underlying tree_node's id field as UInt.

There were two choices to make: one is to export the id, the other is to make a Node hashable based on the id. Investigation shows it's the least confusion solution to export the id field. Details see #26

lijunsong commented 5 months ago

Note: I could clean it up on my end with a squashed commit. But I think you can simply squash it with a click on your end when merge, so I'll let you handle it. Let me know if you need me to clean it.

mattmassicotte commented 5 months ago

This is great, thank you!