Andrew Jeffery
b280138f84
Remove explicit len on index
2022-03-28 10:18:13 +01:00
Andrew Jeffery
1b5730c0ae
Fix insert query to not skip past insert positions
...
When inserting and we have seen enough elements then look for the first
index to insert at rather than skipping over it.
2022-03-28 10:17:46 +01:00
Andrew Jeffery
49c4bf4911
Rename has to has_visible
2022-03-28 10:17:46 +01:00
Andrew Jeffery
a30bdc3888
Add broken list tests
2022-03-28 10:17:46 +01:00
Andrew Jeffery
e945ebbe74
Remove last_elem from nth_at
2022-03-27 15:35:44 +01:00
Andrew Jeffery
20229ee2d0
Remove last_elem in nth query
2022-03-27 15:28:49 +01:00
Andrew Jeffery
83d298ce8d
Add test for broken last_elem
2022-03-27 15:28:49 +01:00
Andrew Jeffery
666782896d
Remove unnecessary consts in queries
2022-03-26 09:11:41 +00:00
Andrew Jeffery
edbfce056c
Merge pull request #317 from jeffa5/experiment-nonzero-start_op
...
Make start_op be nonzero to prevent bad loads
2022-03-24 12:17:28 -05:00
Andrew Jeffery
ed244d980a
Make start_op be nonzero to prevent bad loads
2022-03-24 16:42:46 +00:00
Andrew Jeffery
ec3785ab2b
Expose encoding and decoding errors
2022-03-24 16:20:23 +00:00
Orion Henry
9e1a063bc0
v20 - object replacement char
2022-03-14 14:47:54 -04:00
Andrew Jeffery
a4e8d20266
Optimise getting number of ops when applying tx or changes
2022-03-11 12:25:34 +00:00
Andrew Jeffery
ac18f7116f
And fixup IntoIterator
2022-03-11 12:25:18 +00:00
Andrew Jeffery
67251f4d53
Have splice take IntoIterator
2022-03-11 12:24:02 +00:00
Andrew Jeffery
2e49561ab2
Make splice take iterator instead of vec
2022-03-11 12:13:11 +00:00
Andrew Jeffery
927c867884
Replace no longer returns an op
2022-03-11 12:04:00 +00:00
Andrew Jeffery
488df55385
Remove change field on Op as unused
...
This field was never read from.
2022-03-11 11:40:42 +00:00
Andrew Jeffery
a2cb15e936
Remove obj from the op as it can be gotten from the optree
...
This makes the Op struct smaller, helping memory usage and cache
coherence.
2022-03-11 11:40:28 +00:00
Andrew Jeffery
4b52c2053e
Merge pull request #307 from jeffa5/experiment-apply-change
...
Stop exposing apply_change
2022-03-11 11:39:03 +00:00
Andrew Jeffery
4fa1d056c6
Stop exposing apply_change
...
It doesn't do checks or raise errors so shouldn't really be exposed.
2022-03-10 18:22:06 +00:00
Orion Henry
4ff6dca175
rename error message for foreign objid
2022-03-10 08:47:52 -05:00
Orion Henry
ee116bb5d7
object_type returns an option
2022-03-09 19:42:58 -05:00
Orion Henry
c51073c150
add paths/materialize to api
2022-03-09 17:53:30 -05:00
Orion Henry
5b2582bc04
Merge pull request #301 from jeffa5/experiment-value-api
...
Cleanup value API
2022-03-09 12:06:54 -05:00
Andrew Jeffery
42233414b3
Add some documentation
2022-03-09 16:53:26 +00:00
Andrew Jeffery
266f112e91
Document some sync api
2022-03-09 13:04:10 +00:00
Andrew Jeffery
e26837b09d
Move sync structs to module
2022-03-09 12:43:52 +00:00
Andrew Jeffery
d00cee1637
Misc API updates
...
- Commit now returns just a single hash rather than a vec. Since the
change we create from committing has all of the heads as deps there
can only be one hash/head after committing.
- Apply changes now takes a Vec rather than a slice. This avoids having
to clone them inside.
- transact_with now passes the result of the closure to the commit
options function
- Remove patch struct
- Change receive_sync_message to return a () instead of the
`Option<Patch>`
- Change `Transaction*` structs to just `*` and use the transaction
module
- Make CommitOptions fields public
2022-03-09 12:33:20 +00:00
Andrew Jeffery
3cff67002a
Merge pull request #297 from jeffa5/experiment-del-nothing
...
Add failing tests for deleting nothing
2022-03-09 11:15:22 +00:00
Andrew Jeffery
ebe7bae992
Fix typo on QueryResult
2022-03-09 11:14:21 +00:00
Andrew Jeffery
875bfdd7f2
Update save call
2022-03-09 10:33:57 +00:00
Andrew Jeffery
5f200e3bf5
Update delete nothing tests
2022-03-09 10:31:25 +00:00
Andrew Jeffery
a9737a6815
Fix del missing key in map
2022-03-09 10:31:25 +00:00
Andrew Jeffery
73ac96b7a2
Add failing tests for deleting nothing
2022-03-09 10:31:25 +00:00
Andrew Jeffery
4b32ee882a
Cleanup value API
...
Adds conversions to contained types, is_* methods for checking the
variant and conversions from more types.
2022-03-09 10:28:25 +00:00
Orion Henry
95f27f362c
Merge pull request #283 from jeffa5/experiment-make
...
Separate scalars and objects in transaction API
2022-03-04 16:53:17 -05:00
Orion Henry
6b505419b6
Merge pull request #292 from jeffa5/experiment-actorid-api
...
Cleanup actor id api
2022-03-04 12:44:27 -05:00
Orion Henry
b9acf611fa
Merge pull request #293 from jeffa5/experiment-sync-api
...
Clean up sync api
2022-03-04 12:39:03 -05:00
Orion Henry
390ae49be0
Merge pull request #294 from jeffa5/experiment-infallible-save
...
Make save infallible
2022-03-04 12:37:51 -05:00
Andrew Jeffery
b79da38dea
Merge pull request #295 from jeffa5/experiment-decode-change
...
Make decode_change an associated function
2022-03-04 16:50:19 +00:00
Andrew Jeffery
cd5e734735
Make decode_change an associated function
2022-03-04 13:09:29 +00:00
Andrew Jeffery
a4432bdc3d
Nothing really Into's ObjType so just take it directly
2022-03-04 13:03:19 +00:00
Andrew Jeffery
000576191e
Clean up sync api
2022-03-04 12:32:07 +00:00
Andrew Jeffery
d71e87882e
Make save infallible
2022-03-04 12:28:05 +00:00
Andrew Jeffery
2f3fe0e342
Cleanup actor id api
...
Default can be a footgun and confuse users, it was used internally but
that now uses the `from` impls. Also, opidat wasn't used and doesn't
seem to need to be public.
2022-03-04 12:06:43 +00:00
Andrew Jeffery
555f4c6b98
Unpub ensure_transaction_closed
...
This does the same functionality as a commit but without messages or
timestamps and doesn't return the heads. This shouldn't really be a
public API as they should use commit.
2022-03-04 11:59:51 +00:00
Andrew Jeffery
2ebb3fea6f
Fixup cli
2022-03-04 11:37:44 +00:00
Andrew Jeffery
e1aeb4fd88
Fixup new test after rebase
2022-03-04 11:33:03 +00:00
Andrew Jeffery
b6c9d90d84
Rename value to object in insert_object
2022-03-04 09:51:17 +00:00