mirror of https://git.sr.ht/~stygianentity/bincode
Fixed a copy-paste error where RwLock would report to be a Mutex if it fails to lock
This commit is contained in:
parent
f70e94a427
commit
adc47b6895
|
|
@ -145,7 +145,7 @@ where
|
||||||
{
|
{
|
||||||
fn encode<E: Encoder>(&self, encoder: E) -> Result<(), EncodeError> {
|
fn encode<E: Encoder>(&self, encoder: E) -> Result<(), EncodeError> {
|
||||||
let t = self.read().map_err(|_| EncodeError::LockFailed {
|
let t = self.read().map_err(|_| EncodeError::LockFailed {
|
||||||
type_name: core::any::type_name::<Mutex<T>>(),
|
type_name: core::any::type_name::<RwLock<T>>(),
|
||||||
})?;
|
})?;
|
||||||
t.encode(encoder)
|
t.encode(encoder)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue