Ale*_*nko 6 haskell template-haskell haskell-lens
任何人都可以告诉为什么这段代码不能编译
data A = A {
_b :: B
}
makeLenses ''A
type B = String
Run Code Online (Sandbox Code Playgroud)
与消息
Not in scope: type constructor or class B
Run Code Online (Sandbox Code Playgroud)
这样做:
type B = String
data A = A {
_b :: B
}
makeLenses ''A
Run Code Online (Sandbox Code Playgroud)
没有makeLenses一切编译好.
为什么我不能在makeLenses之后有类型的synonim声明?
| 归档时间: |
|
| 查看次数: |
66 次 |
| 最近记录: |