Safe Haskell | None |
---|
- occurrencesOf :: [String] -> FilePath -> BufLoc -> [FilePath] -> IO [(FilePath, BufSpan)]
- occurrencesOfM :: GhcMonad m => FilePath -> BufLoc -> [FilePath] -> m [(FilePath, BufSpan)]
- showOccurrencesOfResult :: [(FilePath, BufSpan)] -> String
- data BufLoc = BufLoc Int Int
- data BufSpan = BufSpan BufLoc BufLoc
Documentation
:: [String] | A list of ghc options (e.g. |
-> FilePath | The file where the token to rename resides in |
-> BufLoc | The location where the token to rename is |
-> [FilePath] | A list of further files which possibly contain this token and which should be searched for it |
-> IO [(FilePath, BufSpan)] |
This function takes a location, searches out what is at this location and then returns a list of all occurrences of this identifier. This currently works for names of function- and value bindings.
occurrencesOfM :: GhcMonad m => FilePath -> BufLoc -> [FilePath] -> m [(FilePath, BufSpan)]Source
This is the monadic version of occurrencesOf which allows to use this mode of operation from a preconfigured GHC environment.
:: [(FilePath, BufSpan)] | The result that should be shown |
-> String |
This Function formats the results from the occurrencesOf or occurrencesOfM function.
This is just the combination of a line number and a column number.
BufLoc Int Int | BufLoc line column |