summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoey Hess2017-07-13 23:42:17 -0400
committerJoey Hess2017-07-13 23:42:17 -0400
commit020dafc4203a37a57d3a6da12708dc170921c9c6 (patch)
treed4b7e545341e84e0c33c4a61b5e4da1758db2889
parentb72be10661f96976dd3741943313dd7fccf3d782 (diff)
rollbacks
-rw-r--r--doc/todo/differential_update_via_RevertableProperty.mdwn10
1 files changed, 6 insertions, 4 deletions
diff --git a/doc/todo/differential_update_via_RevertableProperty.mdwn b/doc/todo/differential_update_via_RevertableProperty.mdwn
index 6c217944..6d65c916 100644
--- a/doc/todo/differential_update_via_RevertableProperty.mdwn
+++ b/doc/todo/differential_update_via_RevertableProperty.mdwn
@@ -99,7 +99,7 @@ fooisfoo = foo ==# foo
Is, perhaps:
data Version = A | B | C
- deriving (Ord)
+ deriving (Enum, Ord)
foo :: Versioned Host
foo = versionedHost "foo" $ do
@@ -112,9 +112,11 @@ That's ... pretty ok, would hit as least some of the use cases described
above. Seems to need a Reader+Writer monad to implement it,
without passing the Version around explicitly.
-Note that it's allowable for `somethingelse` to not be revertable,
-since once `foo` gets that property, it is never removed.
-So, `inVersion` has to accept both `RevertableProperty` and `Property`.
+Is it allowable for `somethingelse` to not be revertable?
+Once `foo` gets that property, it is never removed if we're moving only
+forwars. On the other hand, perhaps the user will want to roll back to
+version A. Allowing rollbacks seems good, so `inVersion` should only
+accept `RevertableProperty`.
Here's another situation where reversion is not needed: