Skip to content

Conversation

MikaelFangel
Copy link
Contributor

This is a suggestion to use the Float.to_string/1 and Float.to_charlist/1 functions in the String.Chars and List.Chars protocols. Furthermore, it also changes Inspect to use Float.to_charlist/1. The reasoning behind is consistency, so the functions match the others in the protocols.

This PR, updates the functions in the same places as updated in #13046 except for in Float itself.

The changes all refer to these lines in Float:

:erlang.float_to_list(float, [:short])

:erlang.float_to_binary(float, [:short])

@josevalim josevalim merged commit e8821d1 into elixir-lang:main Oct 13, 2024
9 checks passed
@josevalim
Copy link
Member

💚 💙 💜 💛 ❤️

@MikaelFangel MikaelFangel deleted the use_float_functions branch October 13, 2024 09:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants