Importing Elixir libraries to Erlang env

@hudson2010 If I remember correctly Erlang:

  1. " (double quotes) creates in Erlang the same that Elixir is creating with ' (single quote) i.e. charlist
  2. Not sure about UTF-8 binaries, but in Erlang to create binary you need this syntax: <<"Your binary goes here">>.
1> code:add_path("/home/…/.asdf/installs/elixir/1.10.4-otp-23/lib/elixir/ebin/").
true
2> application:start(compiler).                                                     
ok
3> application:start(elixir).
ok
4> 'Elixir.String':downcase(<<"TEST">>).
<<"test">>

For more information please take a look at Strings on Elixir School page.

1 Like