Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for '&' operator (similar to '$') #1201 #1204

Merged
merged 1 commit into from
Jan 15, 2021

Conversation

yairchu
Copy link
Contributor

@yairchu yairchu commented Jan 15, 2021

This appears to work, triggers 3 hints for Lamdu and they appear to be correct :)
I suppose we may also want to add tests for these, but I also suggested #1203 which might be a different solution to consider.

@ndmitchell
Copy link
Owner

Looks good. Could we get some tests? Probably in data/hlint.yaml, something like map f x & concat suggests concatMap f x. Doesn't need to be much, just something to suggest it works.

@yairchu
Copy link
Contributor Author

yairchu commented Jan 15, 2021

something like map f x & concat suggests concatMap f x

Done, added this one and another test

yairchu added a commit to lamdu/lamdu that referenced this pull request Jan 15, 2021
@ndmitchell
Copy link
Owner

Thanks! That second test you wrote of zipWithM is something I'd have never figured out by eye, and the change is very simple, so any doubts I may have originally had about supporting & are certainly alleviated. Nice work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants