diff --git a/libs/aarch64-apple-darwin/librln.a b/libs/aarch64-apple-darwin/librln.a index e40bff4..8f71630 100644 Binary files a/libs/aarch64-apple-darwin/librln.a and b/libs/aarch64-apple-darwin/librln.a differ diff --git a/libs/x86_64-apple-darwin/librln.a b/libs/x86_64-apple-darwin/librln.a index f78fae8..db52cc0 100644 Binary files a/libs/x86_64-apple-darwin/librln.a and b/libs/x86_64-apple-darwin/librln.a differ diff --git a/rln/librln.h b/rln/librln.h index 92201a6..d4061f2 100644 --- a/rln/librln.h +++ b/rln/librln.h @@ -53,6 +53,10 @@ bool atomic_operation(struct RLN *ctx, const struct Buffer *leaves_buffer, const struct Buffer *indices_buffer); +bool seq_atomic_operation(struct RLN *ctx, + const struct Buffer *leaves_buffer, + const struct Buffer *indices_buffer); + bool get_root(const struct RLN *ctx, struct Buffer *output_buffer); bool get_proof(const struct RLN *ctx, uintptr_t index, struct Buffer *output_buffer); diff --git a/rln/wrapper.go b/rln/wrapper.go index 91d8c97..c7f8332 100644 --- a/rln/wrapper.go +++ b/rln/wrapper.go @@ -213,6 +213,12 @@ func (r *RLN) AtomicOperation(index uint, leaves []byte, indices []byte) bool { return bool(C.atomic_operation(r.ptr, C.uintptr_t(index), leavesBuffer, indicesBuffer)) } +func (r *RLN) SeqAtomicOperation(leaves []byte, indices []byte) bool { + leavesBuffer := toCBufferPtr(leaves) + indicesBuffer := toCBufferPtr(indices) + return bool(C.seq_atomic_operation(r.ptr, leavesBuffer, indicesBuffer)) +} + func (r *RLN) DeleteLeaf(index uint) bool { return bool(C.delete_leaf(r.ptr, C.uintptr_t(index))) } diff --git a/zerokit b/zerokit index d015c4a..b51896c 160000 --- a/zerokit +++ b/zerokit @@ -1 +1 @@ -Subproject commit d015c4ab591cb7b260a92a077d3cd1d76609667f +Subproject commit b51896c3a710f567fc7e054681767d6547a8eb9b