Skip to content

Commit

Permalink
Issue #8099: Use , instead of andalso
Browse files Browse the repository at this point in the history
  • Loading branch information
onno-vos-dev committed Feb 14, 2024
1 parent b0983bc commit d7bb143
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/stdlib/src/binary.erl
Original file line number Diff line number Diff line change
Expand Up @@ -950,7 +950,7 @@ _Example:_
-doc(#{since => <<"OTP 27.0">>}).
-spec join([binary()], binary()) -> binary().
join([], _Separator) -> <<>>;
join([H], Separator) when is_binary(H) andalso is_binary(Separator) -> H;
join([H], Separator) when is_binary(H), is_binary(Separator) -> H;
join([H | T], Separator) when is_binary(Separator) ->
%% Starting with an empty binary convinces the compiler to use the new "private append" optimisation
Acc = <<>>,
Expand Down

0 comments on commit d7bb143

Please sign in to comment.