package streamable

  1. Overview
  2. Docs
A collection of types suitable for incremental serialization.

Install

Dune Dependency

Authors

Maintainers

Sources

v0.17.0.tar.gz
sha256=4c59a31870f77b89727e2f986727a2ed865e8336df4b409b716dd6508d9b8a63

doc/src/ppx_streamable/atomic_clause.ml.html

Source file atomic_clause.ml

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
open! Base
open! Import

let maybe_match type_ (_ : Ctx.t) =
  let%bind core_type = Type_.match_core_type type_ in
  let%map () = Attribute.get Attributes.atomic core_type
  and longident_loc = Helpers.if_module_dot_t_then_module core_type in
  ({ children = []
   ; apply_functor =
       (fun ctx children ->
         assert (List.is_empty children);
         Helpers.apply_streamable_dot
           ctx
           ~functor_name:"Of_atomic"
           ~arguments:[ pmod_ident ~loc:ctx.loc longident_loc ])
   }
    : Clause.Match.t)
;;
OCaml

Innovation. Community. Security.