News for hackers. Stuff that matters.
Re:Gleam: A Basic Introduction by lpil on Saturday October 12, 2024 @10:24AM (#41819282)
What do you mean by deal with transpiration? Elixir and LFE also both compile to Erlang and then run the BEAM compiler to generate bytecode. Erlang is the only BEAM language which goes to bytecode directly today.
Re:Gleam: A Basic Introduction by josevalim on Saturday October 12, 2024 @11:10AM (#41819666)
Transpilation usually refers to the fact the target of your compiler is another language source code, which then has to be parsed again. Which leads to issues such as mismatched lines in stacktraces at runtime. Elixir and LFE use the same compiler tooling as Erlang, but the source is parsed just once, and all line information pertains to the original Elixir/LFE source code.
Re:Gleam: A Basic Introduction by lpil on Saturday October 12, 2024 @11:29AM (#41819808)
Gleam also uses that same compiler tooling, though it does not embed the line information presently.
Re:Gleam: A Basic Introduction by josevalim on Saturday October 12, 2024 @12:16PM (#41820199)
Yes, it all goes through the same pipe, but we enter the pipe through different places, which leads to different outcomes. You get different limitations and results depending if your input is Erlang source (Gleam), Erlang AST (Elixir), or Core Erlang AST (which is what LFE used in the past but I am not sure if it is still the case).
Re:Gleam: A Basic Introduction by lpil on Saturday October 12, 2024 @12:40PM (#41820405)
Exactly! Beyond line numbers in stack traces it’s all the same.