Skip to main content

Module write_shape

Module write_shape 

Source
Expand description

Whether a repo’s generated write ops can reject, as a type.

A repo’s create/update return RepoWriteError<CV> when they can hit a constraint and the plain RepoFault when they cannot. A parent repo’s write also runs its nested children’s writes, so the parent can reject if its own statement can or any child’s can. The derive of the parent cannot see the child’s options, so each repo publishes its shapes as WriteShapes on its generated constraint violation enum and the parent folds them with WriteShape::Or. The enum carries them rather than the repo type because it is always pub: a public parent whose signatures mention a less visible child repo would not compile.

Structs§

Faults
The write can reject on nothing: RepoFault.
Rejects
The write can hit a constraint: RepoWriteError<CV>.

Traits§

LiftNestedWrite
Carries the error of a nested child repo’s write into the parent’s vocabulary: a rejection is lifted into the parent’s constraint violation, a fault passes through.
WriteShape
Rejects or Faults.