[GHC] #13584: ghci parse error on operator info

GHC ghc-devs at haskell.org
Mon Apr 17 19:15:08 UTC 2017


#13584: ghci parse error on operator info
-------------------------------------+-------------------------------------
           Reporter:  akegalj        |             Owner:  (none)
               Type:  bug            |            Status:  new
           Priority:  lowest         |         Milestone:
          Component:  GHCi           |           Version:  8.0.2
           Keywords:  parse, info,   |  Operating System:  Linux
  operator                           |
       Architecture:  x86_64         |   Type of failure:  Incorrect result
  (amd64)                            |  at runtime
          Test Case:                 |        Blocked By:
           Blocking:                 |   Related Tickets:
Differential Rev(s):                 |         Wiki Page:
-------------------------------------+-------------------------------------
 If requested info about some operator, ie `(+)` `:info (+)` is working as
 expected:
 {{{#!haskell
 > :i (+)
 class Num a where
   (+) :: a -> a -> a
   ...
         -- Defined in ‘GHC.Num’
 infixl 6 +
 }}}

 When additional space character is there `:info (+ )` it won't parse:
 {{{#!haskell
 > :i (+ )

 <interactive>:1:3: error:
     parse error (possibly incorrect indentation or mismatched brackets)
 }}}

 Note that the same thing is working with `:type` so its strange it doesn't
 use the same parser here and there:ž
 {{{#!haskell
 > :t (+ )
 (+ ) :: Num a => a -> a -> a
 }}}

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/13584>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list