From 47149541e0de423dae39d3a9b0cd14af2f3e85f6 Mon Sep 17 00:00:00 2001 From: Alexandru Vasile Date: Fri, 30 Jun 2023 14:04:09 +0300 Subject: [PATCH 1/2] Expose `PortableType` as public Signed-off-by: Alexandru Vasile --- src/lib.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/lib.rs b/src/lib.rs index 90613705..0e8a6415 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -348,6 +348,7 @@ pub use self::{ portable::{ PortableRegistry, PortableRegistryBuilder, + PortableType, }, registry::{ IntoPortable, From 6003004547cdcbf39ccb5dfa7aca37b3f95001fb Mon Sep 17 00:00:00 2001 From: Alexandru Vasile Date: Fri, 30 Jun 2023 14:08:37 +0300 Subject: [PATCH 2/2] Add documentation for the PortableType' fields Signed-off-by: Alexandru Vasile --- src/portable.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/portable.rs b/src/portable.rs index 133f0594..88bd9e9f 100644 --- a/src/portable.rs +++ b/src/portable.rs @@ -238,8 +238,10 @@ impl PortableRegistry { #[cfg_attr(any(feature = "std", feature = "decode"), derive(scale::Decode))] #[derive(Clone, Debug, PartialEq, Eq, Encode)] pub struct PortableType { + /// The ID of the portable type. #[codec(compact)] pub id: u32, + /// The portable form of the type. #[cfg_attr(feature = "serde", serde(rename = "type"))] pub ty: Type, }