Skip to content

Instantly share code, notes, and snippets.

@aantron
Created May 14, 2017 08:42
Show Gist options
  • Save aantron/9fab0bdead98a60fccf06e0189186863 to your computer and use it in GitHub Desktop.
Save aantron/9fab0bdead98a60fccf06e0189186863 to your computer and use it in GitHub Desktop.
The new lwt.ml, with modules folded
(* OCaml promise library
* http://www.ocsigen.org/lwt
* ...
*)
(* Reading guide
... *)
(* Overview
... *)
(* Some sequence-associated storage types
... *)
module Storage_map = (* ... *)
type storage = (unit -> unit) Storage_map.t
(* Phantom types for use with [promise]/[state]. These must be declared outside
module [Main_internal_types]. This is explained inside. *)
type underlying
type proxy
type completed
type pending
module Main_internal_types = (* ... *)
open Main_internal_types
module Public_types = (* ... *)
include Public_types
module Basic_helpers = (* ... *)
open Basic_helpers
module Sequence_associated_storage = (* ... *)
include Sequence_associated_storage
module Callbacks = (* ... *)
open Callbacks
module Completion_loop = (* ... *)
include Completion_loop
module Trivial_promises = (* ... *)
include Trivial_promises
module Pending_promises = (* ... *)
include Pending_promises
module Sequential_composition = (* ... *)
include Sequential_composition
module Concurrent_composition = (* ... *)
include Concurrent_composition
module Miscellaneous = (* ... *)
include Miscellaneous
module Infix = (* ... *)
include Infix
module Lwt_result_type = (* ... *)
include Lwt_result_type
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment