Inline "speaker" helper function
This commit is contained in:
parent
e2d2338137
commit
ddfa96d685
|
@ -34,11 +34,11 @@
|
|||
|
||||
(define (chat-roles me cout)
|
||||
(define (announce t did-what)
|
||||
(unless (equal? (speaker t) me)
|
||||
(define who (first (topic-pattern t)))
|
||||
(unless (equal? who me)
|
||||
(at-meta-level
|
||||
(cout (term->bytes
|
||||
`(,(speaker t)
|
||||
,did-what))))))
|
||||
`(,who ,did-what))))))
|
||||
(list
|
||||
(role (topic-publisher
|
||||
`(,me says ,(wild))))
|
||||
|
@ -50,9 +50,6 @@
|
|||
[msg (at-meta-level
|
||||
(cout (term->bytes msg)))])))
|
||||
|
||||
(define (speaker t)
|
||||
(first (topic-pattern t)))
|
||||
|
||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||
(define (net-roles me
|
||||
cin cout
|
||||
|
|
Loading…
Reference in New Issue