package core_kernel
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=fd2b8c6715794df7a810a62b226f53720f211cd344b4afc9fab0498796d6b466
doc/core_kernel.flags/Flags/Make/argument-1-M/index.html
Parameter Make.M
val known : (Core.Int63.t * string) list
An entry flag, name
in known
means that the bit(s) in flag
is (are) called name
; i.e. if bit_and flags flag = flag
, then the bit(s) is (are) set and name
will appear in sexp_of_t flags
. known
is only used to make sexp_of_t
's output human readable.
The flags in the output of sexp_of_t
will occur in the same order as they appear in known
.
It is allowed to have a single flag with multiple bits set.
It is an error if different flags intersect, and allow_intersecting = false
.
If remove_zero_flags
, then all flags with value zero will be automatically removed from known
. If not remove_zero_flags
, then it is an error for known
to contain any flags with value zero.
About this existence of this option: it seems better to make it an option here rather than do the filtering at the functor call site. It also makes clear to callers that they need to think about zero flags, and clear what they can do if they encounter them.
allow_intersecting
says whether to allow intersecting known
flags. It is common to do allow_intersecting = false
, however in some situations, e.g. Unix open flags, the flags intersect.