Skip to content

Commit

Permalink
Accept ?Sized references in assert_ser_tokens
Browse files Browse the repository at this point in the history
  • Loading branch information
dtolnay committed Jan 21, 2022
1 parent 1833914 commit 237434f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions serde_test/src/assert.rs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ where
/// ]);
/// ```
#[cfg_attr(track_caller, track_caller)]
pub fn assert_ser_tokens<T>(value: &T, tokens: &[Token])
pub fn assert_ser_tokens<T: ?Sized>(value: &T, tokens: &[Token])
where
T: Serialize,
{
Expand Down Expand Up @@ -113,7 +113,7 @@ where
/// }
/// ```
#[cfg_attr(track_caller, track_caller)]
pub fn assert_ser_tokens_error<T>(value: &T, tokens: &[Token], error: &str)
pub fn assert_ser_tokens_error<T: ?Sized>(value: &T, tokens: &[Token], error: &str)
where
T: Serialize,
{
Expand Down

0 comments on commit 237434f

Please sign in to comment.