-
-
Notifications
You must be signed in to change notification settings - Fork 277
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Made the Cow Encode constraints more permissive (#524)
* Made the Cow Encode constraints more permissive * Made Decode more permissive for Cow
- Loading branch information
1 parent
7ef6fe2
commit dadf335
Showing
3 changed files
with
15 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,3 +20,6 @@ mod issue_498; | |
|
||
#[path = "issues/issue_500.rs"] | ||
mod issue_500; | ||
|
||
#[path = "issues/issue_523.rs"] | ||
mod issue_523; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
#![cfg(all(feature = "derive", feature = "std"))] | ||
|
||
extern crate std; | ||
|
||
use bincode::{Decode, Encode}; | ||
use std::borrow::Cow; | ||
|
||
#[derive(Clone, Encode, Decode)] | ||
pub struct Foo<'a>(Cow<'a, str>); |