Update scale-info to 2.5.0 (#896)

* Upodate scale-info to 2.5.0

* A couple more clippy fixes

* more deprecation things that appeared
This commit is contained in:
James Wilson
2023-04-03 12:52:25 +01:00
committed by GitHub
parent 34f0521fd2
commit c08eb6c8f1
25 changed files with 150 additions and 155 deletions
+3 -3
View File
@@ -87,7 +87,7 @@ impl<T> EncodeAsType for WrapperKeepOpaque<T> {
};
// Do a basic check that the target shape lines up.
let scale_info::TypeDef::Composite(_) = ty.type_def() else {
let scale_info::TypeDef::Composite(_) = ty.type_def else {
return Err(Error::new(ErrorKind::WrongShape {
actual: Kind::Struct,
expected: type_id,
@@ -95,7 +95,7 @@ impl<T> EncodeAsType for WrapperKeepOpaque<T> {
};
// Check that the name also lines up.
if ty.path().ident().as_deref() != Some("WrapperKeepOpaque") {
if ty.path.ident().as_deref() != Some("WrapperKeepOpaque") {
return Err(Error::new(ErrorKind::WrongShape {
actual: Kind::Struct,
expected: type_id,
@@ -188,7 +188,7 @@ mod test {
let mut types = scale_info::Registry::new();
let id = types.register_type(&m);
let portable_registry: scale_info::PortableRegistry = types.into();
(id.id(), portable_registry)
(id.id, portable_registry)
}
fn roundtrips_like_scale_codec<T>(t: T)