Skip to content

Commit

Permalink
Extract out AST-collecting-walker to a separate function + abstract c…
Browse files Browse the repository at this point in the history
…lass (#1154)

* extract out AST-collecting-walker to a separate function + abstract class and use it for range aggregation

* better factoring of the syntax-walking code
  • Loading branch information
baronfel authored Aug 26, 2023
1 parent eda80d8 commit a68786a
Show file tree
Hide file tree
Showing 3 changed files with 692 additions and 652 deletions.
2 changes: 1 addition & 1 deletion src/FsAutoComplete.Core/Commands.fs
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ module Commands =
let getRangesAtPosition (getParseResultsForFile: _ -> Async<Result<FSharpParseFileResults, _>>) file positions =
asyncResult {
let! ast = getParseResultsForFile file
return positions |> List.map (UntypedAstUtils.getRangesAtPosition ast.ParseTree)
return positions |> List.map (FoldingRange.getRangesAtPosition ast.ParseTree)
}

let scopesForFile
Expand Down
Loading

0 comments on commit a68786a

Please sign in to comment.