简体   繁体   English

Hayoo / Hoogle无法将单态/较少多态签名与多态签名匹配

[英]Hayoo/Hoogle not matching monomorphic/less polymorphic signatures with polymorphic ones

I'm trying to understand if there's a fundamental reason for why Hoogle and Hayoo aren't matching, for instance 我正在尝试了解是否有一个为什么Hoogle和Hayoo不匹配的根本原因,例如

(b -> c) -> (b' -> c') ->   (b, b') -> (c, c')

to

a b c    -> a b' c'    ->   a (b, b') (c, c')

which happens to be the type of Control.Arrow.*** : 碰巧是Control.Arrow.***的类型:

(***) :: a b c -> a b' c' -> a (b, b') (c, c')

— is this likely just something that's as-of-yet unimplemented, or is there something fundamental that is preventing this sort of type based search from ever being implemented? —这可能只是尚未实现的事情,还是有某种根本性的因素在阻止这种基于类型的搜索的实现?

With Hoogle, it seems to be a consequence of how -> is handled. 使用Hoogle,这似乎是->处理方式的结果。 Issue #64 in the GitHub tracker , which is very similar to what we are discussing here, includes this comment by Neil Mitchell: GitHub跟踪器中的#64问题与我们在此处讨论的非常相似,其中包含Neil Mitchell的评论:

Currently I quickly split out the result type from the arguments. 目前,我快速从参数中分离出结果类型。 I guess one approach would be to find instances for -> and pregenerate a version with -> substituted in. 我猜一种方法是找到->实例,并用->替换后预生成一个版本。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM