Problem: treesitter parses each diff hunk in isolation, so incomplete syntax constructs at hunk boundaries (e.g., a function definition with no body) produce ERROR nodes and drop captures. Solution: read N lines from the on-disk file before/after each hunk and prepend/append them as unmapped padding lines. The line_map guard in highlight_treesitter skips extmarks for unmapped lines, so padding provides syntax context without visual output. Controlled by highlights.context (default 25, 0 to disable). Also applies to the vim syntax fallback path via a leading_offset filter. |
||
|---|---|---|
| .. | ||
| commands.lua | ||
| debug.lua | ||
| diff.lua | ||
| fugitive.lua | ||
| git.lua | ||
| health.lua | ||
| highlight.lua | ||
| init.lua | ||
| lib.lua | ||
| log.lua | ||
| parser.lua | ||