Skip to content
Snippets Groups Projects
Commit 28e26168 authored by Georgy Moshkin's avatar Georgy Moshkin :speech_balloon:
Browse files

fix: don't ignore context when encoding str enums

parent ca2c09aa
No related branches found
No related tags found
1 merge request!442fix: tweak encode::Context with future backwards compatibility in mind
......@@ -284,9 +284,9 @@ macro_rules! define_str_enum {
fn encode(
&self,
w: &mut impl std::io::Write,
_context: &$crate::msgpack::Context,
context: &$crate::msgpack::Context,
) -> std::result::Result<(), $crate::msgpack::EncodeError> {
<&str as $crate::msgpack::Encode>::encode(&self.as_str(), w, &Default::default())
<&str as $crate::msgpack::Encode>::encode(&self.as_str(), w, context)
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment