GHCi 告诉我 typeA
不是 type A
。为什么?
>>> data A = A
>>> let x = A
>>> let id A = A
>>>
>>> data A = A
>>> let x' = A
>>> let id' A = A
>>>
>>> data A = A
>>>
>>> let y = id' x
<interactive>:18:13:
Couldn't match expected type `main::Interactive.A'
with actual type `main::Interactive.A'
In the first argument of id', namely `x'
In the expression: id' x
In an equation for `y': y = id' x