meraymond2/idris-vscode

Hovering doesn’t take quotes into account

meraymond2 opened this issue · 2 comments

The identifier regex doesn’t include double quotes, so if you hover over a string literal, it will try to get the type of the contents, not the string itself.

Unfortunately, this is more complicated than I had hoped. I could probably make this work for strings without spaces, but not with. Then I'd have issues with multi-line strings. The official advice appears to be to re-parse the entire document if you need to know the type of any particular position, you can't just hijack the text-mate scopes.

I have a naïve but effective fix for this, leaving this comment as a reminder to myself to merge it this weekend.