Skip to content

Conversation

@Martin005
Copy link
Contributor

This PR fixes incorrect table, tr, th and td sourcepos when the paragraph just above the table started with spaces.

Originally, when a paragraph preceding a table contained leading spaces/newlines, the parser updated the paragraph node but didn't update the container's start column. The table node later used that stale column, producing incorrect source positions.

Fixes #591

@Martin005 Martin005 changed the title fix: Incorrect table sourcepos affected by spaces above fix: Incorrect table sourcepos affected by spaces in preceding paragraph Oct 24, 2025
@kivikakk
Copy link
Owner

Awesome — thank you so much.

@kivikakk kivikakk merged commit 25b4bc2 into kivikakk:main Oct 25, 2025
22 of 23 checks passed
@Martin005 Martin005 deleted the table-sourcepos-preceding-paragraph-starting-with-space branch October 25, 2025 08:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Table sourcepos affected by indentation of preceding line.

2 participants