Skip to content

Commit de5ef72

Browse files
committed
check
1 parent 189d739 commit de5ef72

File tree

2 files changed

+4
-10
lines changed

2 files changed

+4
-10
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ the format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/)
77
### changed
88

99
- `.entity_sync` renamed to `.lazy_entity`
10+
- `SignalExt::combine` always `.clone`s its latest upstream outputs no longer `.take`s its stored upstream outputs, instead
1011

1112
### added
1213

src/signal.rs

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1323,10 +1323,7 @@ pub trait SignalExt: Signal {
13231323

13241324
/// Combines this [`Signal`] with another [`Signal`], outputting a tuple with both of their
13251325
/// outputs. The resulting [`Signal`] will only output a value when both input [`Signal`]s have
1326-
/// outputted a value since the last resulting output, e.g. if on frame 1, this [`Signal`]
1327-
/// outputs `1` and the other [`Signal`] outputs `None`, the resulting [`Signal`] will have no
1328-
/// output, but then if on frame 2, this [`Signal`] outputs `None` and the other [`Signal`]
1329-
/// outputs 2, then the resulting [`Signal`] will output `(1, 2)`.
1326+
/// outputted a value.
13301327
///
13311328
/// # Example
13321329
///
@@ -4851,9 +4848,7 @@ mod tests {
48514848

48524849
// Test product with 2 signals
48534850
let product_signal = crate::signal::product!(s1, s2);
4854-
product_signal
4855-
.map(capture_output::<i32>)
4856-
.register(app.world_mut());
4851+
product_signal.map(capture_output::<i32>).register(app.world_mut());
48574852
app.update();
48584853
assert_eq!(app.world().resource::<SignalOutput<i32>>().0, Some(6));
48594854

@@ -4867,9 +4862,7 @@ mod tests {
48674862
let s4 = SignalBuilder::from_system(|_: In<()>| 4);
48684863

48694864
let product_signal = crate::signal::product!(s1, s2, s3, s4);
4870-
product_signal
4871-
.map(capture_output::<i32>)
4872-
.register(app.world_mut());
4865+
product_signal.map(capture_output::<i32>).register(app.world_mut());
48734866
app.update();
48744867
assert_eq!(app.world().resource::<SignalOutput<i32>>().0, Some(24));
48754868
}

0 commit comments

Comments
 (0)