mirror of
https://github.com/tokio-rs/tokio.git
synced 2026-08-24 00:00:11 +02:00
util: Revert "remove Encoder bound on FramedParts constructor" (#5450)
This reverts commit ae69d11d1f.
This commit is contained in:
@@ -368,7 +368,10 @@ pub struct FramedParts<T, U> {
|
|||||||
|
|
||||||
impl<T, U> FramedParts<T, U> {
|
impl<T, U> FramedParts<T, U> {
|
||||||
/// Create a new, default, `FramedParts`
|
/// Create a new, default, `FramedParts`
|
||||||
pub fn new(io: T, codec: U) -> FramedParts<T, U> {
|
pub fn new<I>(io: T, codec: U) -> FramedParts<T, U>
|
||||||
|
where
|
||||||
|
U: Encoder<I>,
|
||||||
|
{
|
||||||
FramedParts {
|
FramedParts {
|
||||||
io,
|
io,
|
||||||
codec,
|
codec,
|
||||||
|
|||||||
Reference in New Issue
Block a user