[erlang-questions] Missing binary BIFs
Andrew Thompson
andrew@REDACTED
Wed Feb 8 19:37:53 CET 2012
On Wed, Feb 08, 2012 at 06:34:23PM +0000, Ignas Vyšniauskas wrote:
> Hi,
>
> On 2012.02.08 18:29, Loïc Hoguin wrote:
> > It feels a bit tedious to keep doing things like
> > list_to_binary(integer_to_list(42))
>
> <<42>> /= <<"42">>, so this would be ambigous.
By that logic, integer_to_list is also ambigous, since [42] /= "42". I
think it's pretty clear what integer_to_binary should do, and there's no
reason to force people to use a list as an intermediate representation.
Andrew
More information about the erlang-questions
mailing list