syndicate-2017/racket/syndicate/examples/example-meta-drop.rkt

14 lines
450 B
Racket
Raw Normal View History

#lang syndicate/core
2015-03-21 22:38:37 +00:00
;; Analogous to nc-incremental-meta-drop.rkt in the Redex model.
;; Demonstrates (hopefully) correct processing of meta-interests when dropping a patch.
2017-02-25 16:16:25 +00:00
(dataspace-actor
(actor (lambda (e u)
2015-03-21 22:38:37 +00:00
(match u
[0 (transition 1 '())]
[1 (transition 2 (retract (outbound 'a)))]
2015-03-21 22:38:37 +00:00
[_ #f]))
0
(patch-seq (assert (outbound 'a))
(assert (observe (inbound 'a))))))