Inferred CallStacks expose implicit parameter
It was noticed (in a thread on ghc-devs) that introducing a CallStack-carrying term into the RHS of a let binding in GHCi produces a type which itself carries a callstack.
I could be wrong but as far as I know this is a bug: the solver should never introduce a constraint that the user didn't write; it should merely provide an empty callstack in the event that a callstack constraint can't be solved.
Prelude> let myList = [1, 2, 3 :: Integer]
Prelude> let myList' = myList ++ undefined
Prelude> :t myList
myList :: [Integer]
Prelude> :t myList'
myList' :: (?callStack::GHC.Stack.Types.CallStack) => [Integer]
Trac metadata
| Trac field | Value |
|---|---|
| Version | 8.0.1-rc2 |
| Type | Bug |
| TypeOfFailure | OtherFailure |
| Priority | high |
| Resolution | Unresolved |
| Component | Compiler (Type checker) |
| Test case | |
| Differential revisions | |
| BlockedBy | |
| Related | |
| Blocking | |
| CC | gridaphobe |
| Operating system | |
| Architecture |
Edited by Eric Seidel