Idris 子句具有不同数量的参数(当混合不可能的模式和效果时)

Idris 子句具有不同数量的参数(当混合不可能的模式和效果时),idris,Idris,使用列表库中的函数tail: tail : (l : List a) -> {auto ok : NonEmpty l} -> List a tail [] {ok=IsNonEmpty} impossible tail (x::xs) {ok=p} = xs 现在尝试用有效的计算替换输出类型: randomIndex : (l : List a) -> {auto ok : NonEmpty l} -> Eff Nat [RND] randomIndex [

使用列表库中的函数
tail

tail : (l : List a) -> {auto ok : NonEmpty l} -> List a
tail []      {ok=IsNonEmpty} impossible
tail (x::xs) {ok=p} = xs
现在尝试用有效的计算替换输出类型:

randomIndex : (l : List a) -> {auto ok : NonEmpty l} -> Eff Nat [RND]
randomIndex []      {ok=IsNonEmpty} impossible
randomIndex (x::xs) {ok=p} = pure 0 -- whatever
您会得到错误
子句具有不同数量的参数

这似乎是错误的。有人知道为什么会这样吗?是否可能是因为
Eff
是某个函数类型的同义词