package b0

  1. Overview
  2. Docs
Software construction and deployment kit

Install

dune-project
 Dependency

Authors

Maintainers

Sources

b0-0.0.6.tbz
sha512=e9aa779e66c08fc763019f16d4706f465d16c05d6400b58fbd0313317ef33ddea51952e2b058db28e65f7ddb7012f328c8bf02d8f1da17bb543348541a2587f0

doc/b0.memo/B0_zero/Guard/index.html

Module B0_zero.GuardSource

Build operation guards.

A guard ensure that a build operation is allowed to proceed. This means either that:

  • It is ready and can be submitted for execution. This happens once all the files the operation reads are ready: they exist and are up-to-date.
  • It is aborted. This happens if a file it needs to read never becomes ready.

Note. This module does not access the file system it trusts clients that call Guard.set_file_ready not to lie about its existence on the file system.

Guards

Sourcetype t

The type for build operations guards.

Sourceval make : unit -> t

make () is a new guard.

Sourceval set_file_ready : t -> B0_std.Fpath.t -> unit

set_file_ready g f indicates to g that file f is ready, i.e. that it exists and is up-to-date.

Sourceval set_file_never : t -> B0_std.Fpath.t -> unit

set_file_never g f indicate to g that file f will never become ready.

Sourceval add : t -> Op.t -> unit

add g o guards o in g until it is allowed.

Sourceval allowed : t -> Op.t option

allowed g is an operation that is either ready or aborted in g (if any). In the second case the Op.status is Op.status.Aborted.

On This Page
  1. Guards