Commit dc27710
Improve LSP benchmark location validation and column resolution
Summary:
_looks_like_valid_location only checked URI parseability and non-negative
coordinates, counting non-existent files and out-of-bounds lines as
valid.
Attribute column resolution used find(token) from line start,
which matched the wrong occurrence when a token appeared multiple times.
Add file-existence and line-bound checks; search from AST col_offset
first, falling back to line start.
Reviewed By: grievejia
Differential Revision: D97012692
fbshipit-source-id: dc2ff552670a6e9ddbbf16683a898680308c6f671 parent f636e9e commit dc27710
1 file changed
+24
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
398 | 398 | | |
399 | 399 | | |
400 | 400 | | |
401 | | - | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
402 | 408 | | |
403 | 409 | | |
404 | 410 | | |
| |||
794 | 800 | | |
795 | 801 | | |
796 | 802 | | |
| 803 | + | |
| 804 | + | |
| 805 | + | |
| 806 | + | |
| 807 | + | |
797 | 808 | | |
798 | 809 | | |
799 | | - | |
| 810 | + | |
800 | 811 | | |
801 | 812 | | |
802 | 813 | | |
| 814 | + | |
| 815 | + | |
| 816 | + | |
803 | 817 | | |
804 | 818 | | |
805 | 819 | | |
806 | 820 | | |
807 | 821 | | |
| 822 | + | |
| 823 | + | |
| 824 | + | |
| 825 | + | |
| 826 | + | |
| 827 | + | |
| 828 | + | |
| 829 | + | |
808 | 830 | | |
809 | 831 | | |
810 | 832 | | |
| |||
0 commit comments