summaryrefslogtreecommitdiff
path: root/src/InteractiveUI.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/InteractiveUI.hs')
-rw-r--r--src/InteractiveUI.hs10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/InteractiveUI.hs b/src/InteractiveUI.hs
index c6e1cf7..1b07d45 100644
--- a/src/InteractiveUI.hs
+++ b/src/InteractiveUI.hs
@@ -1583,10 +1583,14 @@ typeAt str =
do infos <- fmap mod_infos (lift getGHCiState)
result <- findType infos fp sample sl sc el ec
case result of
- Left err -> liftIO (putStrLn err)
- Right (info', ty) ->
+ FindTypeFail err -> liftIO (putStrLn err)
+ FindType info' ty ->
+ printForUserModInfo
+ (modinfoInfo info')
+ (sep [text sample,nest 2 (dcolon <+> ppr ty)])
+ FindTyThing info' tything ->
printForUserModInfo (modinfoInfo info')
- (sep [text sample,nest 2 (dcolon <+> ppr ty)]))
+ (pprTyThing tything))
-----------------------------------------------------------------------------
-- :uses