-
-
Notifications
You must be signed in to change notification settings - Fork 52
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
feat: remove Belt
dependency from Stdlib
#796
Conversation
@@ -96,26 +96,14 @@ let public_method_label s : tag = | |||
(**** Sparse array ****) | |||
|
|||
module Vars = | |||
#ifdef BS | |||
Belt.Map.String |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Users of the standard library will lose this "optimization" to not use a functor, do we want to inline Belt.Map.String perhaps?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a very good question, that I hope I can answer sufficiently:
- I think short term the answer is "we don't care" because the benefits (removing belt as a dep) justify it, and the code becomes the same as the upstream stdlib
- even if it did, I don't think the impact would be important -- and Melange users barely use OCaml objects anyway.
- longer term we want to add continuous benchmarks to melange, which we've added to the next quarter roadmap. Hopefully we can measure the impact of this change retroactively then.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and Melange users barely use OCaml objects anyway.
Not sure I get this part, could you elaborate? How are objects related to the discussion about larger bundles when using functors?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, I see, this is the camlinternalOO
module 🤦
8c96650
to
bd8ff78
Compare
Unreleased | ||
--------------- | ||
|
||
- Remove `Belt` as a dependency of `Stdlib` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a breaking change. Most projects use Dune default config for implicit transitive deps, so they will have to add melange.belt
to the list of libraries
after upgrading. See melange-re/melange-re.github.io#140.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
will mark it as such. thanks!
melange.belt
as a dependency for the melange stdlibmelange.belt
to the libraries that melange auto-includes by default