Determine exact column number for match
This might not be an issue with a high priority, especially as it requires reading the files of the results.
I think it is worth noting down however.
The idea is to get all the files of the grep results (this is already being done in goToDeclaration
to parse them into a file URI)).
Then just read the files using readFileLines
, the line of the result is known through grep as well.
Then indexOf
can be used to determine the character number (not the column number!). To determine the actual column number, tabs should be taken into account. This can be used to return a proper range to the client instead of the line.