[erlang-questions] Atom Unicode Support

Björn Gustavsson bjorn@REDACTED
Mon Feb 1 17:47:53 CET 2016


On Mon, Feb 1, 2016 at 4:48 PM, José Valim
<jose.valim@REDACTED> wrote:
>> I prefer 4 because it is the simplest. For most modules, the
>> chunk will be smaller than for option 3.
>
>
> Should we always emit the new chunk or only if there are unicode atoms?
>

The default should probably be to always use the new
chunk type.

However, there must be an option to make the compiler generate the
old chunk type if possible. There is module called test_server_node
that must be possible to load in both new and old releases.
We use it for compatibility testing. (Note the 'compile(r12)'
attribute in the module.)

See compile:expand_opt/2 and how the options r12, r13, and r14
are handled. (I suggest that you add a new r18 option that turns
off the new atom chunk. You will also need to to update the
r12, r13, and r14 options because io_proto_SUITE in the stdlib
test suite still depends on r12.)

/Björn

-- 
Björn Gustavsson, Erlang/OTP, Ericsson AB



More information about the erlang-questions mailing list