millet
millet copied to clipboard
Exception copy is buggy
Environment
- Millet version: v0.12.2
Steps to reproduce
Given
(*!
* Doc for A
*)
exception A
exception B = A
Try to e.g.:
-
Hover over the usage of
Afor doc. - Try to jump to the def of
Afrom the usage ofA.
Expected behavior
It works.
Actual behavior
It doesn't.
I believe this affects more things than just exception copy. Basically whenever in the grammar we have a name or path that is a usage site that is not directly inside exp or pat, we don’t provide jump to def for that.
This is because the current way we do jump to def is by storing information for the exp or pat idx. We don’t have a way to store jump to def info for an an arbitrary path nested in some gramma structure, such as exception copy or where type.