diff options
| author | eunhhu <[email protected]> | 2026-09-28 09:37:36 +0100 |
|---|---|---|
| committer | eunhhu <[email protected]> | 2026-09-28 09:37:36 +0100 |
| commit | a8232abe41cc168fb1596eb16047133fddd7a9ad (patch) | |
| tree | 42ae607a4e748f7493ec8336684b363254c37fe9 /core/module.h | |
| parent | a557178f92a0b54fd33b9a7aa14ce66a8c45c060 (diff) | |
| download | pure-a8232abe41cc168fb1596eb16047133fddd7a9ad.tar.gz pure-a8232abe41cc168fb1596eb16047133fddd7a9ad.zip | |
Save a list as its items and a journal of its changes since
Diffstat (limited to 'core/module.h')
| -rw-r--r-- | core/module.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/core/module.h b/core/module.h index ed6c062..c8a5f3d 100644 --- a/core/module.h +++ b/core/module.h @@ -265,13 +265,15 @@ typedef struct { PureList *lists[PURE_MODULE_STATES]; PureUndo undo; /* list changes of the current event */ PureDraft *list_drafts[PURE_MODULE_STATES]; /* stored lists, when kept */ + size_t journaled[PURE_MODULE_STATES]; /* a stored list's record bytes after its items */ PureDraft *stored_values; /* numbers, cursors and indices, when kept */ PureVersion saved[PURE_MODULE_STATES]; /* text and list versions at the last save */ /* Events since the last save: what a failed save returns to, and the * documents messages opened (held until the save). */ bool deferred, open; double durable_values[PURE_MODULE_STATES]; - PureVersion durable_texts[PURE_MODULE_STATES], durable_lists[PURE_MODULE_STATES]; + PureVersion durable_texts[PURE_MODULE_STATES]; + size_t durable_lists[PURE_MODULE_STATES]; /* each stored list's journal length */ uint64_t durable_ticks, durable_events; struct PurePending { void *document; char key[65]; bool edited; } *pending; /* grows to PURE_APP_PENDING */ unsigned pending_count, pending_capacity; |
