Rename proc facet(…) to proc inFacet(…)
This commit is contained in:
parent
6f2adf573a
commit
71955f257d
|
@ -38,7 +38,7 @@ export SturdyRef
|
|||
|
||||
export Actor, Assertion, Facet, Handle, Ref, Symbol, Turn, TurnAction,
|
||||
`$`, `?`, addCallback, analyse, asyncCheck, bootDataspace,
|
||||
drop, facet, future, grab, message, newDataspace, publish,
|
||||
drop, facet, future, grab, grabType, inFacet, message, newDataspace, publish,
|
||||
retract, replace, run, stop, unembed
|
||||
|
||||
type
|
||||
|
@ -185,7 +185,6 @@ proc wrapDuringHandler(entryBody, exitBody: NimNode): NimNode =
|
|||
turnSym = ident"turn"
|
||||
bindingsSym = ident"bindings"
|
||||
handleSym = ident"duringHandle"
|
||||
entrySym = genSym(nskProc, "during")
|
||||
duringSym = genSym(nskProc, "during")
|
||||
if exitBody.isNil:
|
||||
quote do:
|
||||
|
|
|
@ -367,10 +367,12 @@ proc stopIfInertAfter(action: TurnAction): TurnAction =
|
|||
stop(turn)
|
||||
wrapper
|
||||
|
||||
proc facet*(turn: var Turn; bootProc: TurnAction): Facet =
|
||||
proc inFacet*(turn: var Turn; bootProc: TurnAction): Facet =
|
||||
result = newFacet(turn.facet.actor, some turn.facet)
|
||||
inFacet(turn, result, stopIfInertAfter(bootProc))
|
||||
|
||||
proc facet*(turn: var Turn; bootProc: TurnAction): Facet {.deprecated.} = inFacet(turn, bootProc)
|
||||
|
||||
proc newActor(name: string; bootProc: TurnAction; initialAssertions: OutboundTable): Actor =
|
||||
let
|
||||
now = getTime()
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
## Module for peering with remote dataspaces over network.
|
||||
|
||||
import std/[asyncdispatch, net, options, streams, tables]
|
||||
import std/[asyncdispatch, net, options, tables]
|
||||
import preserves
|
||||
import ./actors, ./durings, ./relays, ./protocols/protocol
|
||||
|
||||
|
@ -71,7 +71,7 @@ proc connectNet*(turn: var Turn; remote: RemoteSpecifier; cap: SturdyRef; bootPr
|
|||
reenable()
|
||||
discard publish(turn, shutdownRef, true)
|
||||
proc duringCallback(turn: var Turn; a: Assertion; h: Handle): TurnAction =
|
||||
let facet = facet(turn) do (turn: var Turn):
|
||||
let facet = inFacet(turn) do (turn: var Turn):
|
||||
bootProc(turn, unembed a)
|
||||
proc action(turn: var Turn) =
|
||||
stop(turn, facet)
|
||||
|
|
|
@ -340,7 +340,7 @@ when defined(posix):
|
|||
reenable()
|
||||
discard publish(turn, shutdownRef, true)
|
||||
proc duringCallback(turn: var Turn; a: Assertion; h: Handle): TurnAction =
|
||||
let facet = facet(turn) do (turn: var Turn):
|
||||
let facet = inFacet(turn) do (turn: var Turn):
|
||||
bootProc(turn, unembed a)
|
||||
proc action(turn: var Turn) =
|
||||
stop(turn, facet)
|
||||
|
|
Loading…
Reference in New Issue