role/fresh macro

This commit is contained in:
Tony Garnock-Jones 2012-05-03 16:31:05 -04:00
parent 9cf91bb231
commit 7bb49752f4
2 changed files with 6 additions and 1 deletions

View File

@ -3,4 +3,4 @@
(mapcar #'(lambda (x) (put x 'scheme-indent-function 1))
'(transition extend-transition))
(mapcar #'(lambda (x) (put x 'scheme-indent-function 2))
'(role yield)))
'(role role/fresh yield)))

View File

@ -23,6 +23,7 @@
extend-transition
role
role/fresh
(except-out (struct-out add-role) add-role)
(rename-out [make-add-role add-role])
(except-out (struct-out delete-role) delete-role)
@ -186,6 +187,10 @@
topics-expr
(handlers presence-handler absence-handler message-handler)))])))
(define-syntax-rule (role/fresh pre-eid-var rest ...)
(let ((pre-eid-var (gensym 'role)))
(role pre-eid-var rest ...)))
(define-syntax-rule (yield-macro #:state state-pattern body ...)
(yield (match-lambda [state-pattern body ...])))