Skip to content
Snippets Groups Projects

codeintel: fix range-contains off-by-one end character check

Merged Warren Gifford requested to merge nsc/codeintel-ranges-offbyone into main

Created by: Strum355

Fixes the below issue where hovering the following whitespace would give code intel results for the apiFlags variable. This also happens in situations such as Token) where hovering the ) would give the same behaviour. This is due to LSIF ranges specifying half-open intervals aka a range denoted by start-end chars as 2, 10 would be [2, 10): \t\tapiFlags 0 1 234567890

The ComparePosition function changed in this PR did not account for that final index not being part of the range.

image

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading