Fix Ambiguous Highlights#275
Conversation
…olwinter/CodeEditSourceEditor into feat/multiple-highlighters
…olwinter/CodeEditSourceEditor into feat/multiple-highlighters
austincondiff
left a comment
There was a problem hiding this comment.
Nice work, and very well documented! I found a few potential issues. Let me know your thoughts.
@austincondiff most of these changes are from #273 so I think we need to wait to review this until that is merged so the actual changes are visible here. Sorry I made it convoluted. The things you commented on are from that PR |
|
Would it be better to set the #273 branch as the target and merge into it instead? |
|
|
|
Okay the changes shown here now reflect the actual diff. I'm not too worried about the messy commit history since we squash PRs anyways. Ready for review now! |
Description
Fixes some bad syntax highlighting caused by overlapping captures returned from tree-sitter. Previously the last value returned took precedence, but with the new highlighting system that's not the case. This filters highlights on duplicate ranges, and prioritizes the best capture for any range so this is no longer dependent on the highlighting system's semantics.
Related Issues
Checklist
Screenshots
Disambiguated highlights:
Ambiguous highlights: