lspitzner / lspitzner/czipwith

Instances always can, and should, use lazy pattern matching

Open
#1 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Haskell
Stars
2
Forks
3
PR merge metrics
No merged PRs in 30d

Description

This should be a note accompanying the laws, or a new law that explicitly names bottom.

for the derived instances, we should change from e.g.

~~~~.hs
instance CZipWith A where
cZipWith f (A x1 x2) (A y1 y2) = A (f x1 y1) (f x2 y2)
~~~~

to
~~~~.hs
instance CZipWith A where
cZipWith f ~(A x1 x2) ~(A y1 y2) = A (f x1 y1) (f x2 y2)
~~~~

(and similar for the other derivings.)

Contributor guide

No contributing guide indexed for this repository

Research direction

Locate the derived CZipWith instances and the laws documentation mentioned in the issue. Check how the current instances handle pattern matching, then update the relevant instances or law text so bottom and lazy patterns are explicitly covered; done means the derived instances consistently use the requested lazy patterns.

Written by the indexing model from the issue text.

Assessment

Tech stack
haskell
Domain
tooling
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.