package ocsigenserver-compat
Install
dune-project
Dependency
Authors
Maintainers
Sources
md5=be7a28e3a79cc028d35c88eca538ee8b
sha512=08cdaab31864aeba743ad0c03077a6eccf1089e7b7c4078045dab9409d409144b70cc546df7881b64b780689eee642ca2391be84ab2a6a8ffee0fbed2ad5ac98
doc/ocsigenserver-compat.baselib/Ocsigen_lib/index.html
Module Ocsigen_libSource
include module type of struct include Ocsigen_base.Lib end
include module type of Ocsigen_lib_base
with type poly = Ocsigen_lib_base.poly
and type yesnomaybe = Ocsigen_lib_base.yesnomaybe
and type 'a Clist.t = 'a Ocsigen_lib_base.Clist.t
and type 'a Clist.node = 'a Ocsigen_lib_base.Clist.node
include module type of Lwt.Infix
p >>= f is the same as Lwt.bind p f. It requires Lwt.Infix to be opened in scope:
open Lwt.Infix
let () =
Lwt_main.run
(Lwt_io.(read_line stdin) >>= Lwt_io.printl)
(* ocamlfind opt -linkpkg -thread -package lwt.unix code.ml && ./a.out *)It is recommended to use the PPX let%lwt syntax instead. This operator is the next-best choice. It is frequently found while reading existing Lwt code.
p >|= f is the same as Lwt.map f p. It requires Lwt.Infix to be opened in scope.
open Lwt.Infix
let () =
Lwt_main.run
(Lwt_io.(read_line stdin) >|= ignore)
(* ocamlfind opt -linkpkg -thread -package lwt.unix code.ml && ./a.out *)p1 <&> p2 is the same as Lwt.join [p1; p2]. It requires Lwt.Infix to be opened in scope.
Unlike with Lwt.bind and Lwt.map, there are no problems with explicit Lwt.join syntax, so using this operator is not recommended.
p1 <?> p2 is the same as Lwt.choose [p1; p2]. It requires Lwt.Infix to be opened in scope.
Unlike with Lwt.bind and Lwt.map, there are no problems with explicit Lwt.choose syntax, so using this operator is not recommended.
Furthermore, most users actually need Lwt.pick instead of Lwt.choose.
f =<< p is the same as Lwt.bind p f. It requires Lwt.Infix to be opened in scope.
This operator is obscure and its use is discouraged. It is the same as p >>= f.
f =|< p is the same as Lwt.map f p. It requires Lwt.Infix to be opened in scope.
This operator is obscure and its use is discouraged. It is the same as p >|= f.
module Let_syntax = Ocsigen_base.Lib.Let_syntaxThis module provides support for ppx_let.
val (!!) : 'a Lazy.t -> 'amodule Tuple3 = Ocsigen_base.Lib.Tuple3type poly = Ocsigen_lib_base.polyval to_poly : 'a -> polyval from_poly : poly -> 'amodule List = Ocsigen_base.Lib.ListImprovement of module List
module Clist = Ocsigen_base.Lib.ClistCircular lists
module Int = Ocsigen_base.Lib.Intmodule String_base = Ocsigen_base.Lib.String_baseImprovement of module String
module Url_base = Ocsigen_base.Lib.Url_baseGenerate an unique and cryptographically safe random string. It is impossible to guess for other people and will never return twice the same value (with very good probabilities).
module String = Ocsigen_base.Lib.Stringmodule Ip_address = Ocsigen_base.Lib.Ip_addressmodule Filename = Ocsigen_base.Lib.Filenamemodule Url = Ocsigen_base.Lib.Url