Support stopping a root facet, such as happens when a link between actors is broken
This commit is contained in:
parent
5455392efc
commit
20b83aa5a5
|
@ -302,11 +302,15 @@ export class Turn {
|
|||
}
|
||||
|
||||
stop(facet: Facet = this.activeFacet, continuation?: LocalAction) {
|
||||
this.enqueue(facet.parent!, () => {
|
||||
if (facet.parent === null) {
|
||||
this.stopActor();
|
||||
} else {
|
||||
this.enqueue(facet.parent, () => {
|
||||
facet._terminate(true);
|
||||
if (continuation) continuation();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
// Alias for syndicatec code generator to use
|
||||
_spawn(bootProc: LocalAction, initialAssertions = new IdentitySet<Handle>()): void {
|
||||
|
|
Loading…
Reference in New Issue