summaryrefslogtreecommitdiff
path: root/2d/signals.scm
diff options
context:
space:
mode:
Diffstat (limited to '2d/signals.scm')
-rw-r--r--2d/signals.scm13
1 files changed, 5 insertions, 8 deletions
diff --git a/2d/signals.scm b/2d/signals.scm
index 018684c..04de9c0 100644
--- a/2d/signals.scm
+++ b/2d/signals.scm
@@ -181,14 +181,11 @@ onto SIGNAL1, SIGNAL2, SIGNAL3, and SIGNAL4."
(signal-ref signal4)))
#:connectors (list signal1 signal2 signal3 signal4)))
-(define (signal-merge signal1 signal2)
- "Create a new signal that merges SIGNAL1 and SIGNAL2 into one. The
-value of the new signal is the value of the most recently changed
-parent signal."
- (make-signal
- #:transformer (lambda (value prev from)
- value)
- #:connectors (list signal1 signal2)))
+(define (signal-merge . signals)
+ "Create a new signal that merges every signal in the list SIGNALS
+into one. The value of the new signal is the value of the most
+recently changed signal in the list."
+ (make-signal #:connectors signals))
(define (signal-combine . signals)
"Create a new signal that combines the values of SIGNALS into a