#7253: Top-level bindings in ghci
------------------------------+---------------------------------------------
Reporter: Feuerbach | Owner:
Type: feature request | Status: new
Priority: normal | Component: GHCi
Version: 7.6.1 | Keywords:
Os: Unknown/Multiple | Architecture: Unknown/Multiple
Failure: Other | Testcase:
Blockedby: | Blocking:
Related: |
------------------------------+---------------------------------------------
ghci now supports most of the declarations. However, it doesn't support
the most basic and common type of declaraion — pattern and function
bindings!
E.g.
{{{
Prelude> a = 1
<interactive>:2:3: parse error on input `='
}}}
I realise that, if implemented, they would have somewhat different
semantics than in Haskell modules — e.g. with respect to recursion.
But even if they behaved in the same way as top-level monadic let-
bindings, they would still be very useful for two reasons:
1. If you're doing quick experiments in ghci, "let a=1" is more than twice
as long as "a=1", and that makes a difference.
2. Novices are often confused when they are told that they have to use one
syntax for definitions in modules and another in ghci.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7253>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs