Impossible to create an instance of the Costrong class
还没有人认领这个 Issue。
评估
- 难度
- 5/5
- 预计耗时
- 一周以上
- 新手友好度
- 25/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 停滞
- 领域
- backend
调研方向
Start by reading the Costrong class and its unfirst method; the issue gives no file or test paths, so locate them in the repository. Compare the strict definition with the proposed Lazy constraint and consider the naming or library scope raised in the issue. Done means establishing whether the proposed approach is viable and agreeing on the API direction.
由索引模型根据 Issue 内容生成。
描述
The reason that Function and other types cannot be an instance of Costrong is that PureScript is a strict evaluation.
unfirst :: forall a b c. p (Tuple a c) (Tuple b c) -> p a b
That is, when we want to loop over c, it is impossible to set the initial value of c
How to modify it may be debatable, but I found the following solution
unfirstLazy :: forall a b c. Lazy c => p (Tuple a c) (Tuple b c) -> p a b
unfirstLazy f a = fst $ f $ Tuple a $ go
where
go = snd $ f $ Tuple a $ defer \_ -> go
Also, since this is not "Co" Strong, it might be better to name the class differently, for example CostrongLazy, or create a new library.
Thanks to natefaubion for sharing this issue on PureScript discord server.
- 主要语言
- PureScript
- 星标
- 34
- 派生
- 13
- 平均合并
- 3 天 10 分钟
- 30 天内合并 PR
- 1
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 没有贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
purescript/purescript-profunctor 的其他 Issue
-
难度 4/5 3-5 天 新手友好度 28/100
purescript/purescript-profunctor#49 · 1 条评论 ·
-
status: needs more info
难度 5/5 一周以上 新手友好度 25/100
purescript/purescript-profunctor#32 · 1 条评论 ·
-
type: enhancement
难度 5/5 一周以上 新手友好度 20/100
查看 purescript/purescript-profunctor 的全部 Issue
相似的 Issue
-
ManageSieve proxy: a backend's NO/BYE greeting is skipped as a capability line and reported as EOF未关闭bug
难度 2/5 1-3 小时 新手友好度 72/100
维护者通常 1 天内回复
-
Mend: dependency security vulnerability
难度 2/5 1-3 小时 新手友好度 62/100
ManageIQ/manageiq-pods#1476 ·
维护者通常 1 天内回复
-
mcp: typed tool handlers lose wrapped JSON-RPC errors可能重新可做 关联的 PR 已关闭且未合并。 未关闭
难度 2/5 1-3 小时 新手友好度 85/100
modelcontextprotocol/go-sdk#1529 · 1 条评论 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 66/100
FinanceFlash/unvibecode#818 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 70/100