[erlang-questions] list manipulation
Wed Sep 5 10:27:01 CEST 2012
Thanks for the clue. I see some vals > 255. That must be the problem.
On 9/5/2012 10:07 AM, Erik Søe Sørensen wrote:
> Does the list contain non-bytes - ie, values > 255 (or <0)?
> Is the list pure (ie, ends with )?
> What you're probably looking for is the encoding functions in the 'unicode'
> Den 05/09/2012 08.57 skrev "Martin Dimitrov" <>:
>> I have a list, representing a UTF8 string, containing more than 225000
>> elements. I have load it in var L:
>> 8> lists:flatten(L).
>> 9> list_to_binary(L).
>> ** exception error: bad argument
>> in function list_to_binary/1
>> called as
>> 10> file:write_file("data.txt", L).
>> Why list_to_binary/1 and write_file/2 fail?
>> Best regards,
>> erlang-questions mailing list
More information about the erlang-questions