-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Add binary:join/2 to stdlib #8099
Labels
Comments
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
…ch returns an empty binary
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
…ch returns an empty binary
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
…ch returns an empty binary
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
…optimisation and ensure we start appending from an empty binary
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
…ngle element and ensure it is a binary
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 8, 2024
…dd guard to ensure Separator is a binary
onno-vos-dev
added a commit
to onno-vos-dev/otp
that referenced
this issue
Feb 14, 2024
bjorng
pushed a commit
that referenced
this issue
Nov 7, 2024
bjorng
added a commit
that referenced
this issue
Nov 7, 2024
…-to-stdlib Issue #8099: Add binary:join/2 to stdlib OTP-19337
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Is your feature request related to a problem? Please describe.
Too often now have I simply copy-pasted a version of binary_join/2 to a project I'm working on. A very basic Github search (q=binary_join+language%3AErlang+&type=code) shows how widespread this copy-pasting behaviour actually is. Surely one can use:
iolist_to_binary(lists:join(Separator, Binaries))
to achieve the same thing but benchmarking a correct implementation ofbinary:join/2
shows a significant performance difference between the two:Describe the solution you'd like
Implement
binary:join/2
intobinary.erl
so that we can once and for all stop the copy-pasting! 😄Describe alternatives you've considered
iolist_to_binary(lists:join(Separator, Binaries))
is a widespread alternative but it's much slower.Additional context
N/A
The text was updated successfully, but these errors were encountered: