qdk icon indicating copy to clipboard operation
qdk copied to clipboard

Language Server: Add Local Kind to Hover Card for Locals

Open ScottCarda-MS opened this issue 2 years ago • 1 comments

It would be a nice to add a little more information to the hover cards for locals, by way of adding the appropriate declaration keyword to the the local's hover card. i.e. let, mutable, use, borrow and nothing for for-loop iterators.

This needs looking into to see how this can be done and further design considerations.

ScottCarda-MS avatar Sep 05 '23 19:09 ScottCarda-MS

One issue with this come from the HIR pass to remove use statements and sanitize all qubit declarations to use immutable let bindings. This can make it difficult to distinguish between use and borrow for qubit references, and use and let for qubit alias declarations (use q = Qubit; let w = q;).

ScottCarda-MS avatar Sep 05 '23 19:09 ScottCarda-MS