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

Allow disabling hashable dependency #155

Closed
wants to merge 1 commit into from

Conversation

414owen
Copy link

@414owen 414owen commented Jan 6, 2024

This allows people to disable the Hashable instance, and dependency.
To keep compatibility, it's implemented as a flag that defaults to true.
I think that if async were to release a new major version, it would be good to implement this as a sublibrary instead.

@414owen 414owen force-pushed the os/allow-disabling-hashable branch 2 times, most recently from 7a4854c to 4b9de0a Compare January 6, 2024 11:22
Introduces the hashable flag, which controls the
dependency on `hashable`.
@414owen 414owen force-pushed the os/allow-disabling-hashable branch from 4b9de0a to c40b142 Compare January 6, 2024 11:40
@simonmar
Copy link
Owner

What's the rationale for this?

@414owen
Copy link
Author

414owen commented Jan 13, 2024

I have a project that I'm keeping quite lean, and at the moment async is one of the two dependencies that depends on hashable.

In general, minimizing dependency footprints gives us some small wins:

  • Faster (first-time) compile times (eg in CI)
  • Faster link times
  • Smaller binary sizes
  • Easier ghc upgrades (almost certainly not an issue with hashable)

Admittedly I might be scraping the bottom of the barrel trying to get rid of hashable... Feel free to close this.

@simonmar
Copy link
Owner

This seems to me a very narrow use case and not worth adding conditional compilation for. If there's a lot of demand then I'll reconsider. Closing for now.

@simonmar simonmar closed this Jan 20, 2024
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