References, and code actions that add a match's clauses and fill holes
textDocument/references and documentHighlight give the uses of the name at point in its module, found as go to definition finds a binding: a local, a top-level definition, a type or a constructor, or an imported name where the module uses it. Uses.fs holds the search, which Rename now shares. textDocument/codeAction offers what the compiler worked out while it checked (Exhaustiveness.observe, Holes.observe, kept by Fixes.fs): at an incomplete match, the clauses it lacks, lined up after its last clause with holes as bodies; at a typed hole, a binding in scope that fits, a constructor of its type with holes for what it takes, or a fun. Version 0.7.0. 🤖 Generated with [ECA](https://eca.dev) Co-Authored-By: eca-agent <git@eca.dev>
This commit is contained in:
parent
853b7c3163
commit
23b6a0e55c
9 changed files with 634 additions and 60 deletions
5
Check.fs
5
Check.fs
|
|
@ -232,8 +232,9 @@ let file (buffers: Map<string, string>) (path: string) : Found list =
|
|||
Diagnostics.captured (fun () ->
|
||||
try
|
||||
Expansion.recording path (fun () ->
|
||||
Types.recording path (Option.defaultValue "" text) (fun () ->
|
||||
Session.isolated (fun () -> Build.compile options path)))
|
||||
Fixes.recording path (fun () ->
|
||||
Types.recording path (Option.defaultValue "" text) (fun () ->
|
||||
Session.isolated (fun () -> Build.compile options path))))
|
||||
with ex ->
|
||||
printfn "%s" (Diagnostics.humanize ex.Message)
|
||||
1)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue