addDataspace
This commit is contained in:
parent
68432a204c
commit
be22238ca3
|
@ -30,9 +30,9 @@ import ./syndicate/[actors, dataspaces, durings, patterns]
|
||||||
|
|
||||||
from ./syndicate/relays import connectStdio, connectUnix
|
from ./syndicate/relays import connectStdio, connectUnix
|
||||||
|
|
||||||
export Assertion, Facet, Handle, Ref, Symbol, Turn, TurnAction, bootDataspace,
|
export Assertion, Facet, Handle, Ref, Symbol, Turn, TurnAction, `$`, `?`,
|
||||||
`$`, `?`, connectStdio, connectUnix, drop, facet, grab, message, publish,
|
bootDataspace, connectStdio, connectUnix, drop, facet, grab, message,
|
||||||
retract, replace, run, stop, unembed
|
newDataspace, publish, retract, replace, run, stop, unembed
|
||||||
|
|
||||||
proc `?`*(T: static typedesc): Pattern =
|
proc `?`*(T: static typedesc): Pattern =
|
||||||
## Construct a `Pattern` from type `T`.
|
## Construct a `Pattern` from type `T`.
|
||||||
|
|
|
@ -42,3 +42,6 @@ proc bootDataspace*(name: string; bootProc: BootProc): Actor {.discardable.} =
|
||||||
discard turn.facet.preventInertCheck()
|
discard turn.facet.preventInertCheck()
|
||||||
let ds = newRef(turn, Dataspace(index: initIndex()))
|
let ds = newRef(turn, Dataspace(index: initIndex()))
|
||||||
bootProc(ds, turn)
|
bootProc(ds, turn)
|
||||||
|
|
||||||
|
proc newDataspace*(turn: var Turn): Ref =
|
||||||
|
newRef(turn, Dataspace(index: initIndex()))
|
||||||
|
|
Loading…
Reference in New Issue