-
Notifications
You must be signed in to change notification settings - Fork 87
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
Simplify implementation of internal FFI function intercalate in Data.Show.Generic #274
Conversation
I didn't add a changelog entry for this, since this change shouldn't be visible to any users. |
@cdepillabout This can be added to the CHANGELOG under the "Other improvements" section if you would like, but it isn't necessary if you don't want to. |
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.
Perhaps a changelog should be added for other backend maintainers because the function name is changing from join
to intercalate
?
…how to intercalate.
Thanks for the review. I've added a CHANGELOG entry for this change. Hopefully this should be good to merge now. |
I'd like to merge this, but I'll clarify how this change affects non-JS backends before doing so. While this isn't a breaking change for the JS backend, I wonder if it is for non-JS backends. |
Per Nate, this counts as a breaking change for non-JS backends. So, we shouldn't merge it until we're making breaking changes in general. I've added that label here. |
Description of the change
The
Data.Show
andData.Show.Generic
modules both use an internal FFI helper functionintercalate
. It was calledjoin
inData.Show
.This PR does the following:
Data.Show.Generic.intercalate
. This now matches the same (simple) implementation fromData.Show
.Data.Show
to beintercalate
. My reasoning is that the function should be named the same thing in bothData.Show
andData.Show.Generic
. I thoughtintercalate
would be easier to understand for a PureScriter, sinceintercalate
is already used in modules likeData.Foldable
. (Alternatively,intercalate
could be renamedjoin
in both modules, sincejoin
is the name of the underlying FFI function. I decided against this sincejoin
has a different meaning in PureScript. I thoughtintercalate
was easier to understand.)Checklist: