aboutsummaryrefslogtreecommitdiffstats
path: root/lib/concepts/BranchState.mli
diff options
context:
space:
mode:
authorMarcos Magueta <maguetamarcos@gmail.com>2026-08-01 14:22:05 -0300
committerGitHub <noreply@github.com>2026-08-01 14:22:05 -0300
commitd512411992a6a2b50fcdf03689129f70f530116f (patch)
tree03c0cec59ae2bfd20ef5af00e6a01bb2fe5dab2d /lib/concepts/BranchState.mli
parent117fe888ef9325dbc6965e36c38e40c92d7bc1ee (diff)
downloadRNT-d512411992a6a2b50fcdf03689129f70f530116f.tar.gz
RNT-d512411992a6a2b50fcdf03689129f70f530116f.zip
Initialization with Branch State and Index
Diffstat (limited to 'lib/concepts/BranchState.mli')
-rw-r--r--lib/concepts/BranchState.mli17
1 files changed, 17 insertions, 0 deletions
diff --git a/lib/concepts/BranchState.mli b/lib/concepts/BranchState.mli
new file mode 100644
index 0000000..45792cc
--- /dev/null
+++ b/lib/concepts/BranchState.mli
@@ -0,0 +1,17 @@
+type t
+type address = Hash.hash
+
+include Object.S with type t := t
+
+(** Durable state of one branch head.
+
+ [current] is the branch-visible catalog root, not the runtime namespace
+ rooted at [/system]. Runtime scaffolding is rebuilt during initialization.
+ [history] is the ordered commit-stream tree root. [tip] is absent until the
+ first real commit, so initialization does not create a synthetic commit just
+ to make the branch non-empty. *)
+val make : current:address -> history:address -> tip:address option -> t
+
+val current : t -> address
+val history : t -> address
+val tip : t -> address option