You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For proper streaming scenarios like tokio-trace where implementors of its Subscriber trait will want to hold on to a stream across an arbitrary number of calls.
It means callers would then be able to call Value::stream(1, &mut value::Stream::new(stream)). This might also be confusing within Value implementations. It needs some thought.
The text was updated successfully, but these errors were encountered:
Alternatively, we could introduce an value::OwnedStream that wraps up a generic T: stream::Stream and debug stack, and can be borrowed as a value::Stream.
The current value::Stream expects to be borrowed, so it's not useful for scenarios where you need to own the stream across calls, and having an owned variant we can borrow from avoids having to introduce a branch into every streaming call for a Cow-like approach that bungs an owned or borrowed stream into the same structure.
For proper streaming scenarios like
tokio-trace
where implementors of itsSubscriber
trait will want to hold on to a stream across an arbitrary number of calls.It means callers would then be able to call
Value::stream(1, &mut value::Stream::new(stream))
. This might also be confusing withinValue
implementations. It needs some thought.The text was updated successfully, but these errors were encountered: