This commit is contained in:
Jaremy Creechley 2023-08-24 18:57:06 -07:00 committed by Dmitriy Ryajov
parent 28097881f8
commit 8644cbc9dc
No known key found for this signature in database
GPG Key ID: DA8C680CE7C657A4
2 changed files with 3 additions and 3 deletions

View File

@ -75,14 +75,14 @@ method close*(
# TODO: how to handle failed close?
return success()
func newSharedDataStore*(
proc newSharedDataStore*(
# T: typedesc[SharedDatastore],
backend: ThreadBackend,
): ?!SharedDatastore =
var
self = SharedDatastore()
res = newThreadResult(ThreadDatastore)
res = newThreadResult(ThreadDatastorePtr)
res[].signal = newSignal()
res.createThreadDatastore(backend)

View File

@ -51,7 +51,7 @@ type
ThreadDatastorePtr* = SharedPtr[ThreadDatastore]
proc newThreadResult*[T](tp: typedesc[TResult[T]]): TResult[T] =
proc newThreadResult*[T](tp: typedesc[T]): UniquePtr[ThreadResult[T]] =
newUniquePtr(ThreadResult[T])
proc startupDatastore(