Skip to content

Fix operator precedence in TextLine.HitTest line-break check#112

Open
Beldaa wants to merge 1 commit intotoptensoftware:mainfrom
Beldaa:fix/hittest-operator-precedence
Open

Fix operator precedence in TextLine.HitTest line-break check#112
Beldaa wants to merge 1 commit intotoptensoftware:mainfrom
Beldaa:fix/hittest-operator-precedence

Conversation

@Beldaa
Copy link
Copy Markdown

@Beldaa Beldaa commented Apr 18, 2026

Fixes #111

The paragraph separator (0x2029) check bypassed the Length > 0 guard due to && binding tighter than ||. This could cause an IndexOutOfRangeException when hit-testing near paragraph separators with empty code point runs.
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.

Operator precedence bug in TextLine.HitTest paragraph separator check

1 participant