package sqlgg

  1. Overview
  2. Docs
SQL Guided (code) Generator

Install

Dune Dependency

Authors

Maintainers

Sources

sqlgg-20231201.tar.gz
md5=0841965b140612b9b1fb066cc21f88cb
sha256=7fbee5972b8fa0488bf31bb482101c93c328f67ceef3e95af165d554736d78fe
sha512=5d14e03e02f62c72c57cc574fd9f637e99118556a739af16d71e8813a8cbd8c330e48d69b9577ef2e9d0227aee9d85664cb4907f479927b7431e0475d954fa1a

doc/src/sqlgg.traits/sqlgg_io.ml.html

Source file sqlgg_io.ml

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
(**
  OCaml IO signature for sqlgg
  by Raman Varabets
  2018-12-19

  This is free and unencumbered software released into the public domain.

  Anyone is free to copy, modify, publish, use, compile, sell, or
  distribute this software, either in source code form or as a compiled
  binary, for any purpose, commercial or non-commercial, and by any
  means.

  For more information, please refer to <http://unlicense.org/>
*)

module type M = sig
  type 'a future
  val return : 'a -> 'a future
  val (>>=) : 'a future -> ('a -> 'b future) -> 'b future
  val bracket : 'a future -> ('a -> unit future) -> ('a -> 'b future) -> 'b future
end

module Blocking : M with type 'a future = 'a = struct

  type 'a future = 'a

  let return x = x

  let (>>=) x f = f x

  let bracket x dtor f =
    let r = try f x with exn -> dtor x; raise exn in
    dtor x;
    r

end
OCaml

Innovation. Community. Security.