lpil / erlcaml

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

OCaml Erlang

# Compile
jbuilder build

# Run
jbuild exec erlcaml
# Dump OCaml Lambda IR
ocamlc -c -dlambda thing.ml
% Dump Core Erlang IR to file
compile:file("thing.erl", [to_core]).

% Compile core Erlang from file
compile:file("hand_written_core_mod.core", [from_core]).
% Dump Erlang AST to file
compile:file("thing.erl", [dpp]).

% Compile Erlang AST from file
File = "hand_written_pp_mod.pp".
{ok, Mod, Forms} = file:consult(File).
code:load_binary(Mod, File, Forms).

Notes

About


Languages

Language:Erlang 43.3%Language:Common Lisp 26.9%Language:Makefile 18.0%Language:OCaml 11.8%