diff options
author | Alan Zimmerman <alan.zimm@gmail.com> | 2015-11-22 23:41:57 +0100 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2015-11-23 00:07:43 +0100 |
commit | 3df9563e590bbfbfe1bc9171a0e8fc93ceef690d (patch) | |
tree | 5e63328de5de41c66f089284d75e7251c4085db1 /utils | |
parent | 64737f2dfa0ff9ca4f4c056143b3591cedd32652 (diff) | |
download | haskell-3df9563e590bbfbfe1bc9171a0e8fc93ceef690d.tar.gz |
ApiAnnotations: Make all RdrName occurences Located
At the moment the API Annotations can only be used on the ParsedSource,
as there are changes made to the RenamedSource that prevent it from
being used to round trip source code.
It is possible to build a map from every Located Name in the
RenamedSource from its location to the Name, which can then be used when
resolved names are required when changing the ParsedSource.
However, there are instances where the identifier is not located,
specifically
(GHC.VarPat name)
(GHC.HsVar name)
(GHC.UserTyVar name)
(GHC.HsTyVar name)
Replace each of the name types above with (Located name)
Updates the haddock submodule.
Test Plan: ./validate
Reviewers: austin, goldfire, bgamari
Reviewed By: bgamari
Subscribers: goldfire, thomie, mpickering
Differential Revision: https://phabricator.haskell.org/D1512
GHC Trac Issues: #11019
Diffstat (limited to 'utils')
-rw-r--r-- | utils/ghctags/Main.hs | 2 | ||||
m--------- | utils/haddock | 0 |
2 files changed, 1 insertions, 1 deletions
diff --git a/utils/ghctags/Main.hs b/utils/ghctags/Main.hs index cfc795601d..7bbec3065d 100644 --- a/utils/ghctags/Main.hs +++ b/utils/ghctags/Main.hs @@ -289,7 +289,7 @@ boundThings modname lbinding = lid id = FoundThing modname (getOccString id) loc in case unLoc lpat of WildPat _ -> tl - VarPat name -> lid name : tl + VarPat (L _ name) -> lid name : tl LazyPat p -> patThings p tl AsPat id p -> patThings p (thing id : tl) ParPat p -> patThings p tl diff --git a/utils/haddock b/utils/haddock -Subproject e763c004c8eb067ed0ef510fda9cb4ab102ea6a +Subproject fcd1bb7177a800f6f56a623c2468fc46a59c527 |