let main () : unit Deferred.t =
let open Lambda in
let id = Lambda ("x", Var "x") in
let small_omega = Lambda ("x", App (Var "x", Var "x")) in
let big_omega = App (small_omega, small_omega) in
let kvs = [
("id", id);
("omega", small_omega);
("Omega", big_omega);
] in
let db = LevelDB.open_db "/tmp/lambda" in
put_all db kvs >>= fun () ->
get db "id" >>= fun id ->
get db "omega" >>= fun small_omega ->
get db "Omega" >>= fun big_omega ->
print_endline (Option.value (Option.map id ~f:to_string) ~default:"not found");
print_endline (Option.value (Option.map small_omega ~f:to_string) ~default:"not found");
print_endline (Option.value (Option.map big_omega ~f:to_string) ~default:"not found");
LevelDB.close db;
return ()