glob
glob copied to clipboard
Serialize and Deserialize with serde
I would like to be able to serialize and deserialize Pattern
with serde.
It is of course always possible with the newtype pattern,
but it would be nice if this functionality would come with this crate directly, or at least with a companion-create, so everyone can use the same implementation without reinventing the wheel, and also being compatible amongst each other.
I imagine the solution would be one of:
- newtype
- derive (similar to https://github.com/tailhook/serde-regex for Regex), or
- directly available on
Pattern
, either- by default or
- only when activating a feature
What do you say?