From 39d7dbb0c12bd422ee43a6e2e3277789da4eaac8 Mon Sep 17 00:00:00 2001 From: Leigh McCulloch <351529+leighmcculloch@users.noreply.github.com> Date: Tue, 3 Sep 2024 09:16:22 +1000 Subject: [PATCH] Update with stellar-xdr containing split interface (#389) * Update with stellar-xdr containing split interface * update next too * update curr * fix curr * upd --- src/curr/generated.rs | 116 ++++++++++++++++++++++++++++++++++++++---- src/next/generated.rs | 116 ++++++++++++++++++++++++++++++++++++++---- xdr/curr | 2 +- xdr/curr-version | 2 +- xdr/next | 2 +- xdr/next-version | 2 +- 6 files changed, 216 insertions(+), 24 deletions(-) diff --git a/src/curr/generated.rs b/src/curr/generated.rs index df135f77..7894b6fb 100644 --- a/src/curr/generated.rs +++ b/src/curr/generated.rs @@ -26,7 +26,7 @@ pub const XDR_FILES_SHA256: [(&str, &str); 12] = [ ), ( "xdr/curr/Stellar-contract-env-meta.x", - "928a30de814ee589bc1d2aadd8dd81c39f71b7e6f430f56974505ccb1f49654b", + "75a271414d852096fea3283c63b7f2a702f2905f78fc28eb60ec7d7bd366a780", ), ( "xdr/curr/Stellar-contract-meta.x", @@ -5282,13 +5282,61 @@ impl WriteXdr for ScEnvMetaKind { } } +/// ScEnvMetaEntryInterfaceVersion is an XDR NestedStruct defines as: +/// +/// ```text +/// struct { +/// uint32 protocol; +/// uint32 preRelease; +/// } +/// ``` +/// +#[derive(Clone, Debug, Hash, PartialEq, Eq, PartialOrd, Ord)] +#[cfg_attr(feature = "arbitrary", derive(Arbitrary))] +#[cfg_attr( + all(feature = "serde", feature = "alloc"), + derive(serde::Serialize, serde::Deserialize), + serde(rename_all = "snake_case") +)] +#[cfg_attr(feature = "schemars", derive(schemars::JsonSchema))] +pub struct ScEnvMetaEntryInterfaceVersion { + pub protocol: u32, + pub pre_release: u32, +} + +impl ReadXdr for ScEnvMetaEntryInterfaceVersion { + #[cfg(feature = "std")] + fn read_xdr(r: &mut Limited) -> Result { + r.with_limited_depth(|r| { + Ok(Self { + protocol: u32::read_xdr(r)?, + pre_release: u32::read_xdr(r)?, + }) + }) + } +} + +impl WriteXdr for ScEnvMetaEntryInterfaceVersion { + #[cfg(feature = "std")] + fn write_xdr(&self, w: &mut Limited) -> Result<()> { + w.with_limited_depth(|w| { + self.protocol.write_xdr(w)?; + self.pre_release.write_xdr(w)?; + Ok(()) + }) + } +} + /// ScEnvMetaEntry is an XDR Union defines as: /// /// ```text /// union SCEnvMetaEntry switch (SCEnvMetaKind kind) /// { /// case SC_ENV_META_KIND_INTERFACE_VERSION: -/// uint64 interfaceVersion; +/// struct { +/// uint32 protocol; +/// uint32 preRelease; +/// } interfaceVersion; /// }; /// ``` /// @@ -5303,7 +5351,7 @@ impl WriteXdr for ScEnvMetaKind { #[cfg_attr(feature = "schemars", derive(schemars::JsonSchema))] #[allow(clippy::large_enum_variant)] pub enum ScEnvMetaEntry { - ScEnvMetaKindInterfaceVersion(u64), + ScEnvMetaKindInterfaceVersion(ScEnvMetaEntryInterfaceVersion), } impl ScEnvMetaEntry { @@ -5361,7 +5409,9 @@ impl ReadXdr for ScEnvMetaEntry { #[allow(clippy::match_same_arms, clippy::match_wildcard_for_single_variants)] let v = match dv { ScEnvMetaKind::ScEnvMetaKindInterfaceVersion => { - Self::ScEnvMetaKindInterfaceVersion(u64::read_xdr(r)?) + Self::ScEnvMetaKindInterfaceVersion(ScEnvMetaEntryInterfaceVersion::read_xdr( + r, + )?) } #[allow(unreachable_patterns)] _ => return Err(Error::Invalid), @@ -46106,6 +46156,7 @@ pub enum TypeVariant { ConfigSettingEntry, ScEnvMetaKind, ScEnvMetaEntry, + ScEnvMetaEntryInterfaceVersion, ScMetaV0, ScMetaKind, ScMetaEntry, @@ -46541,7 +46592,7 @@ pub enum TypeVariant { } impl TypeVariant { - pub const VARIANTS: [TypeVariant; 458] = [ + pub const VARIANTS: [TypeVariant; 459] = [ TypeVariant::Value, TypeVariant::ScpBallot, TypeVariant::ScpStatementType, @@ -46568,6 +46619,7 @@ impl TypeVariant { TypeVariant::ConfigSettingEntry, TypeVariant::ScEnvMetaKind, TypeVariant::ScEnvMetaEntry, + TypeVariant::ScEnvMetaEntryInterfaceVersion, TypeVariant::ScMetaV0, TypeVariant::ScMetaKind, TypeVariant::ScMetaEntry, @@ -47001,7 +47053,7 @@ impl TypeVariant { TypeVariant::BinaryFuseFilterType, TypeVariant::SerializedBinaryFuseFilter, ]; - pub const VARIANTS_STR: [&'static str; 458] = [ + pub const VARIANTS_STR: [&'static str; 459] = [ "Value", "ScpBallot", "ScpStatementType", @@ -47028,6 +47080,7 @@ impl TypeVariant { "ConfigSettingEntry", "ScEnvMetaKind", "ScEnvMetaEntry", + "ScEnvMetaEntryInterfaceVersion", "ScMetaV0", "ScMetaKind", "ScMetaEntry", @@ -47492,6 +47545,7 @@ impl TypeVariant { Self::ConfigSettingEntry => "ConfigSettingEntry", Self::ScEnvMetaKind => "ScEnvMetaKind", Self::ScEnvMetaEntry => "ScEnvMetaEntry", + Self::ScEnvMetaEntryInterfaceVersion => "ScEnvMetaEntryInterfaceVersion", Self::ScMetaV0 => "ScMetaV0", Self::ScMetaKind => "ScMetaKind", Self::ScMetaEntry => "ScMetaEntry", @@ -47941,7 +47995,7 @@ impl TypeVariant { #[must_use] #[allow(clippy::too_many_lines)] - pub const fn variants() -> [TypeVariant; 458] { + pub const fn variants() -> [TypeVariant; 459] { Self::VARIANTS } @@ -47988,6 +48042,9 @@ impl TypeVariant { Self::ConfigSettingEntry => gen.into_root_schema_for::(), Self::ScEnvMetaKind => gen.into_root_schema_for::(), Self::ScEnvMetaEntry => gen.into_root_schema_for::(), + Self::ScEnvMetaEntryInterfaceVersion => { + gen.into_root_schema_for::() + } Self::ScMetaV0 => gen.into_root_schema_for::(), Self::ScMetaKind => gen.into_root_schema_for::(), Self::ScMetaEntry => gen.into_root_schema_for::(), @@ -48666,6 +48723,7 @@ impl core::str::FromStr for TypeVariant { "ConfigSettingEntry" => Ok(Self::ConfigSettingEntry), "ScEnvMetaKind" => Ok(Self::ScEnvMetaKind), "ScEnvMetaEntry" => Ok(Self::ScEnvMetaEntry), + "ScEnvMetaEntryInterfaceVersion" => Ok(Self::ScEnvMetaEntryInterfaceVersion), "ScMetaV0" => Ok(Self::ScMetaV0), "ScMetaKind" => Ok(Self::ScMetaKind), "ScMetaEntry" => Ok(Self::ScMetaEntry), @@ -49160,6 +49218,7 @@ pub enum Type { ConfigSettingEntry(Box), ScEnvMetaKind(Box), ScEnvMetaEntry(Box), + ScEnvMetaEntryInterfaceVersion(Box), ScMetaV0(Box), ScMetaKind(Box), ScMetaEntry(Box), @@ -49595,7 +49654,7 @@ pub enum Type { } impl Type { - pub const VARIANTS: [TypeVariant; 458] = [ + pub const VARIANTS: [TypeVariant; 459] = [ TypeVariant::Value, TypeVariant::ScpBallot, TypeVariant::ScpStatementType, @@ -49622,6 +49681,7 @@ impl Type { TypeVariant::ConfigSettingEntry, TypeVariant::ScEnvMetaKind, TypeVariant::ScEnvMetaEntry, + TypeVariant::ScEnvMetaEntryInterfaceVersion, TypeVariant::ScMetaV0, TypeVariant::ScMetaKind, TypeVariant::ScMetaEntry, @@ -50055,7 +50115,7 @@ impl Type { TypeVariant::BinaryFuseFilterType, TypeVariant::SerializedBinaryFuseFilter, ]; - pub const VARIANTS_STR: [&'static str; 458] = [ + pub const VARIANTS_STR: [&'static str; 459] = [ "Value", "ScpBallot", "ScpStatementType", @@ -50082,6 +50142,7 @@ impl Type { "ConfigSettingEntry", "ScEnvMetaKind", "ScEnvMetaEntry", + "ScEnvMetaEntryInterfaceVersion", "ScMetaV0", "ScMetaKind", "ScMetaEntry", @@ -50634,6 +50695,11 @@ impl Type { TypeVariant::ScEnvMetaEntry => r.with_limited_depth(|r| { Ok(Self::ScEnvMetaEntry(Box::new(ScEnvMetaEntry::read_xdr(r)?))) }), + TypeVariant::ScEnvMetaEntryInterfaceVersion => r.with_limited_depth(|r| { + Ok(Self::ScEnvMetaEntryInterfaceVersion(Box::new( + ScEnvMetaEntryInterfaceVersion::read_xdr(r)?, + ))) + }), TypeVariant::ScMetaV0 => { r.with_limited_depth(|r| Ok(Self::ScMetaV0(Box::new(ScMetaV0::read_xdr(r)?)))) } @@ -52676,6 +52742,13 @@ impl Type { ReadXdrIter::<_, ScEnvMetaEntry>::new(&mut r.inner, r.limits.clone()) .map(|r| r.map(|t| Self::ScEnvMetaEntry(Box::new(t)))), ), + TypeVariant::ScEnvMetaEntryInterfaceVersion => Box::new( + ReadXdrIter::<_, ScEnvMetaEntryInterfaceVersion>::new( + &mut r.inner, + r.limits.clone(), + ) + .map(|r| r.map(|t| Self::ScEnvMetaEntryInterfaceVersion(Box::new(t)))), + ), TypeVariant::ScMetaV0 => Box::new( ReadXdrIter::<_, ScMetaV0>::new(&mut r.inner, r.limits.clone()) .map(|r| r.map(|t| Self::ScMetaV0(Box::new(t)))), @@ -54660,6 +54733,13 @@ impl Type { ReadXdrIter::<_, Frame>::new(&mut r.inner, r.limits.clone()) .map(|r| r.map(|t| Self::ScEnvMetaEntry(Box::new(t.0)))), ), + TypeVariant::ScEnvMetaEntryInterfaceVersion => Box::new( + ReadXdrIter::<_, Frame>::new( + &mut r.inner, + r.limits.clone(), + ) + .map(|r| r.map(|t| Self::ScEnvMetaEntryInterfaceVersion(Box::new(t.0)))), + ), TypeVariant::ScMetaV0 => Box::new( ReadXdrIter::<_, Frame>::new(&mut r.inner, r.limits.clone()) .map(|r| r.map(|t| Self::ScMetaV0(Box::new(t.0)))), @@ -56923,6 +57003,10 @@ impl Type { ReadXdrIter::<_, ScEnvMetaEntry>::new(dec, r.limits.clone()) .map(|r| r.map(|t| Self::ScEnvMetaEntry(Box::new(t)))), ), + TypeVariant::ScEnvMetaEntryInterfaceVersion => Box::new( + ReadXdrIter::<_, ScEnvMetaEntryInterfaceVersion>::new(dec, r.limits.clone()) + .map(|r| r.map(|t| Self::ScEnvMetaEntryInterfaceVersion(Box::new(t)))), + ), TypeVariant::ScMetaV0 => Box::new( ReadXdrIter::<_, ScMetaV0>::new(dec, r.limits.clone()) .map(|r| r.map(|t| Self::ScMetaV0(Box::new(t)))), @@ -58778,6 +58862,9 @@ impl Type { TypeVariant::ScEnvMetaEntry => { Ok(Self::ScEnvMetaEntry(Box::new(serde_json::from_reader(r)?))) } + TypeVariant::ScEnvMetaEntryInterfaceVersion => Ok( + Self::ScEnvMetaEntryInterfaceVersion(Box::new(serde_json::from_reader(r)?)), + ), TypeVariant::ScMetaV0 => Ok(Self::ScMetaV0(Box::new(serde_json::from_reader(r)?))), TypeVariant::ScMetaKind => Ok(Self::ScMetaKind(Box::new(serde_json::from_reader(r)?))), TypeVariant::ScMetaEntry => { @@ -60054,6 +60141,11 @@ impl Type { TypeVariant::ScEnvMetaEntry => Ok(Self::ScEnvMetaEntry(Box::new( serde::de::Deserialize::deserialize(r)?, ))), + TypeVariant::ScEnvMetaEntryInterfaceVersion => { + Ok(Self::ScEnvMetaEntryInterfaceVersion(Box::new( + serde::de::Deserialize::deserialize(r)?, + ))) + } TypeVariant::ScMetaV0 => Ok(Self::ScMetaV0(Box::new( serde::de::Deserialize::deserialize(r)?, ))), @@ -61451,6 +61543,7 @@ impl Type { Self::ConfigSettingEntry(ref v) => v.as_ref(), Self::ScEnvMetaKind(ref v) => v.as_ref(), Self::ScEnvMetaEntry(ref v) => v.as_ref(), + Self::ScEnvMetaEntryInterfaceVersion(ref v) => v.as_ref(), Self::ScMetaV0(ref v) => v.as_ref(), Self::ScMetaKind(ref v) => v.as_ref(), Self::ScMetaEntry(ref v) => v.as_ref(), @@ -61920,6 +62013,7 @@ impl Type { Self::ConfigSettingEntry(_) => "ConfigSettingEntry", Self::ScEnvMetaKind(_) => "ScEnvMetaKind", Self::ScEnvMetaEntry(_) => "ScEnvMetaEntry", + Self::ScEnvMetaEntryInterfaceVersion(_) => "ScEnvMetaEntryInterfaceVersion", Self::ScMetaV0(_) => "ScMetaV0", Self::ScMetaKind(_) => "ScMetaKind", Self::ScMetaEntry(_) => "ScMetaEntry", @@ -62377,7 +62471,7 @@ impl Type { #[must_use] #[allow(clippy::too_many_lines)] - pub const fn variants() -> [TypeVariant; 458] { + pub const fn variants() -> [TypeVariant; 459] { Self::VARIANTS } @@ -62419,6 +62513,7 @@ impl Type { Self::ConfigSettingEntry(_) => TypeVariant::ConfigSettingEntry, Self::ScEnvMetaKind(_) => TypeVariant::ScEnvMetaKind, Self::ScEnvMetaEntry(_) => TypeVariant::ScEnvMetaEntry, + Self::ScEnvMetaEntryInterfaceVersion(_) => TypeVariant::ScEnvMetaEntryInterfaceVersion, Self::ScMetaV0(_) => TypeVariant::ScMetaV0, Self::ScMetaKind(_) => TypeVariant::ScMetaKind, Self::ScMetaEntry(_) => TypeVariant::ScMetaEntry, @@ -62957,6 +63052,7 @@ impl WriteXdr for Type { Self::ConfigSettingEntry(v) => v.write_xdr(w), Self::ScEnvMetaKind(v) => v.write_xdr(w), Self::ScEnvMetaEntry(v) => v.write_xdr(w), + Self::ScEnvMetaEntryInterfaceVersion(v) => v.write_xdr(w), Self::ScMetaV0(v) => v.write_xdr(w), Self::ScMetaKind(v) => v.write_xdr(w), Self::ScMetaEntry(v) => v.write_xdr(w), diff --git a/src/next/generated.rs b/src/next/generated.rs index b64e8248..8d00bed2 100644 --- a/src/next/generated.rs +++ b/src/next/generated.rs @@ -26,7 +26,7 @@ pub const XDR_FILES_SHA256: [(&str, &str); 12] = [ ), ( "xdr/next/Stellar-contract-env-meta.x", - "928a30de814ee589bc1d2aadd8dd81c39f71b7e6f430f56974505ccb1f49654b", + "75a271414d852096fea3283c63b7f2a702f2905f78fc28eb60ec7d7bd366a780", ), ( "xdr/next/Stellar-contract-meta.x", @@ -5347,13 +5347,61 @@ impl WriteXdr for ScEnvMetaKind { } } +/// ScEnvMetaEntryInterfaceVersion is an XDR NestedStruct defines as: +/// +/// ```text +/// struct { +/// uint32 protocol; +/// uint32 preRelease; +/// } +/// ``` +/// +#[derive(Clone, Debug, Hash, PartialEq, Eq, PartialOrd, Ord)] +#[cfg_attr(feature = "arbitrary", derive(Arbitrary))] +#[cfg_attr( + all(feature = "serde", feature = "alloc"), + derive(serde::Serialize, serde::Deserialize), + serde(rename_all = "snake_case") +)] +#[cfg_attr(feature = "schemars", derive(schemars::JsonSchema))] +pub struct ScEnvMetaEntryInterfaceVersion { + pub protocol: u32, + pub pre_release: u32, +} + +impl ReadXdr for ScEnvMetaEntryInterfaceVersion { + #[cfg(feature = "std")] + fn read_xdr(r: &mut Limited) -> Result { + r.with_limited_depth(|r| { + Ok(Self { + protocol: u32::read_xdr(r)?, + pre_release: u32::read_xdr(r)?, + }) + }) + } +} + +impl WriteXdr for ScEnvMetaEntryInterfaceVersion { + #[cfg(feature = "std")] + fn write_xdr(&self, w: &mut Limited) -> Result<()> { + w.with_limited_depth(|w| { + self.protocol.write_xdr(w)?; + self.pre_release.write_xdr(w)?; + Ok(()) + }) + } +} + /// ScEnvMetaEntry is an XDR Union defines as: /// /// ```text /// union SCEnvMetaEntry switch (SCEnvMetaKind kind) /// { /// case SC_ENV_META_KIND_INTERFACE_VERSION: -/// uint64 interfaceVersion; +/// struct { +/// uint32 protocol; +/// uint32 preRelease; +/// } interfaceVersion; /// }; /// ``` /// @@ -5368,7 +5416,7 @@ impl WriteXdr for ScEnvMetaKind { #[cfg_attr(feature = "schemars", derive(schemars::JsonSchema))] #[allow(clippy::large_enum_variant)] pub enum ScEnvMetaEntry { - ScEnvMetaKindInterfaceVersion(u64), + ScEnvMetaKindInterfaceVersion(ScEnvMetaEntryInterfaceVersion), } impl ScEnvMetaEntry { @@ -5426,7 +5474,9 @@ impl ReadXdr for ScEnvMetaEntry { #[allow(clippy::match_same_arms, clippy::match_wildcard_for_single_variants)] let v = match dv { ScEnvMetaKind::ScEnvMetaKindInterfaceVersion => { - Self::ScEnvMetaKindInterfaceVersion(u64::read_xdr(r)?) + Self::ScEnvMetaKindInterfaceVersion(ScEnvMetaEntryInterfaceVersion::read_xdr( + r, + )?) } #[allow(unreachable_patterns)] _ => return Err(Error::Invalid), @@ -46445,6 +46495,7 @@ pub enum TypeVariant { ConfigSettingEntry, ScEnvMetaKind, ScEnvMetaEntry, + ScEnvMetaEntryInterfaceVersion, ScMetaV0, ScMetaKind, ScMetaEntry, @@ -46883,7 +46934,7 @@ pub enum TypeVariant { } impl TypeVariant { - pub const VARIANTS: [TypeVariant; 462] = [ + pub const VARIANTS: [TypeVariant; 463] = [ TypeVariant::Value, TypeVariant::ScpBallot, TypeVariant::ScpStatementType, @@ -46911,6 +46962,7 @@ impl TypeVariant { TypeVariant::ConfigSettingEntry, TypeVariant::ScEnvMetaKind, TypeVariant::ScEnvMetaEntry, + TypeVariant::ScEnvMetaEntryInterfaceVersion, TypeVariant::ScMetaV0, TypeVariant::ScMetaKind, TypeVariant::ScMetaEntry, @@ -47347,7 +47399,7 @@ impl TypeVariant { TypeVariant::BinaryFuseFilterType, TypeVariant::SerializedBinaryFuseFilter, ]; - pub const VARIANTS_STR: [&'static str; 462] = [ + pub const VARIANTS_STR: [&'static str; 463] = [ "Value", "ScpBallot", "ScpStatementType", @@ -47375,6 +47427,7 @@ impl TypeVariant { "ConfigSettingEntry", "ScEnvMetaKind", "ScEnvMetaEntry", + "ScEnvMetaEntryInterfaceVersion", "ScMetaV0", "ScMetaKind", "ScMetaEntry", @@ -47845,6 +47898,7 @@ impl TypeVariant { Self::ConfigSettingEntry => "ConfigSettingEntry", Self::ScEnvMetaKind => "ScEnvMetaKind", Self::ScEnvMetaEntry => "ScEnvMetaEntry", + Self::ScEnvMetaEntryInterfaceVersion => "ScEnvMetaEntryInterfaceVersion", Self::ScMetaV0 => "ScMetaV0", Self::ScMetaKind => "ScMetaKind", Self::ScMetaEntry => "ScMetaEntry", @@ -48297,7 +48351,7 @@ impl TypeVariant { #[must_use] #[allow(clippy::too_many_lines)] - pub const fn variants() -> [TypeVariant; 462] { + pub const fn variants() -> [TypeVariant; 463] { Self::VARIANTS } @@ -48347,6 +48401,9 @@ impl TypeVariant { Self::ConfigSettingEntry => gen.into_root_schema_for::(), Self::ScEnvMetaKind => gen.into_root_schema_for::(), Self::ScEnvMetaEntry => gen.into_root_schema_for::(), + Self::ScEnvMetaEntryInterfaceVersion => { + gen.into_root_schema_for::() + } Self::ScMetaV0 => gen.into_root_schema_for::(), Self::ScMetaKind => gen.into_root_schema_for::(), Self::ScMetaEntry => gen.into_root_schema_for::(), @@ -49035,6 +49092,7 @@ impl core::str::FromStr for TypeVariant { "ConfigSettingEntry" => Ok(Self::ConfigSettingEntry), "ScEnvMetaKind" => Ok(Self::ScEnvMetaKind), "ScEnvMetaEntry" => Ok(Self::ScEnvMetaEntry), + "ScEnvMetaEntryInterfaceVersion" => Ok(Self::ScEnvMetaEntryInterfaceVersion), "ScMetaV0" => Ok(Self::ScMetaV0), "ScMetaKind" => Ok(Self::ScMetaKind), "ScMetaEntry" => Ok(Self::ScMetaEntry), @@ -49533,6 +49591,7 @@ pub enum Type { ConfigSettingEntry(Box), ScEnvMetaKind(Box), ScEnvMetaEntry(Box), + ScEnvMetaEntryInterfaceVersion(Box), ScMetaV0(Box), ScMetaKind(Box), ScMetaEntry(Box), @@ -49971,7 +50030,7 @@ pub enum Type { } impl Type { - pub const VARIANTS: [TypeVariant; 462] = [ + pub const VARIANTS: [TypeVariant; 463] = [ TypeVariant::Value, TypeVariant::ScpBallot, TypeVariant::ScpStatementType, @@ -49999,6 +50058,7 @@ impl Type { TypeVariant::ConfigSettingEntry, TypeVariant::ScEnvMetaKind, TypeVariant::ScEnvMetaEntry, + TypeVariant::ScEnvMetaEntryInterfaceVersion, TypeVariant::ScMetaV0, TypeVariant::ScMetaKind, TypeVariant::ScMetaEntry, @@ -50435,7 +50495,7 @@ impl Type { TypeVariant::BinaryFuseFilterType, TypeVariant::SerializedBinaryFuseFilter, ]; - pub const VARIANTS_STR: [&'static str; 462] = [ + pub const VARIANTS_STR: [&'static str; 463] = [ "Value", "ScpBallot", "ScpStatementType", @@ -50463,6 +50523,7 @@ impl Type { "ConfigSettingEntry", "ScEnvMetaKind", "ScEnvMetaEntry", + "ScEnvMetaEntryInterfaceVersion", "ScMetaV0", "ScMetaKind", "ScMetaEntry", @@ -51023,6 +51084,11 @@ impl Type { TypeVariant::ScEnvMetaEntry => r.with_limited_depth(|r| { Ok(Self::ScEnvMetaEntry(Box::new(ScEnvMetaEntry::read_xdr(r)?))) }), + TypeVariant::ScEnvMetaEntryInterfaceVersion => r.with_limited_depth(|r| { + Ok(Self::ScEnvMetaEntryInterfaceVersion(Box::new( + ScEnvMetaEntryInterfaceVersion::read_xdr(r)?, + ))) + }), TypeVariant::ScMetaV0 => { r.with_limited_depth(|r| Ok(Self::ScMetaV0(Box::new(ScMetaV0::read_xdr(r)?)))) } @@ -53087,6 +53153,13 @@ impl Type { ReadXdrIter::<_, ScEnvMetaEntry>::new(&mut r.inner, r.limits.clone()) .map(|r| r.map(|t| Self::ScEnvMetaEntry(Box::new(t)))), ), + TypeVariant::ScEnvMetaEntryInterfaceVersion => Box::new( + ReadXdrIter::<_, ScEnvMetaEntryInterfaceVersion>::new( + &mut r.inner, + r.limits.clone(), + ) + .map(|r| r.map(|t| Self::ScEnvMetaEntryInterfaceVersion(Box::new(t)))), + ), TypeVariant::ScMetaV0 => Box::new( ReadXdrIter::<_, ScMetaV0>::new(&mut r.inner, r.limits.clone()) .map(|r| r.map(|t| Self::ScMetaV0(Box::new(t)))), @@ -55090,6 +55163,13 @@ impl Type { ReadXdrIter::<_, Frame>::new(&mut r.inner, r.limits.clone()) .map(|r| r.map(|t| Self::ScEnvMetaEntry(Box::new(t.0)))), ), + TypeVariant::ScEnvMetaEntryInterfaceVersion => Box::new( + ReadXdrIter::<_, Frame>::new( + &mut r.inner, + r.limits.clone(), + ) + .map(|r| r.map(|t| Self::ScEnvMetaEntryInterfaceVersion(Box::new(t.0)))), + ), TypeVariant::ScMetaV0 => Box::new( ReadXdrIter::<_, Frame>::new(&mut r.inner, r.limits.clone()) .map(|r| r.map(|t| Self::ScMetaV0(Box::new(t.0)))), @@ -57378,6 +57458,10 @@ impl Type { ReadXdrIter::<_, ScEnvMetaEntry>::new(dec, r.limits.clone()) .map(|r| r.map(|t| Self::ScEnvMetaEntry(Box::new(t)))), ), + TypeVariant::ScEnvMetaEntryInterfaceVersion => Box::new( + ReadXdrIter::<_, ScEnvMetaEntryInterfaceVersion>::new(dec, r.limits.clone()) + .map(|r| r.map(|t| Self::ScEnvMetaEntryInterfaceVersion(Box::new(t)))), + ), TypeVariant::ScMetaV0 => Box::new( ReadXdrIter::<_, ScMetaV0>::new(dec, r.limits.clone()) .map(|r| r.map(|t| Self::ScMetaV0(Box::new(t)))), @@ -59248,6 +59332,9 @@ impl Type { TypeVariant::ScEnvMetaEntry => { Ok(Self::ScEnvMetaEntry(Box::new(serde_json::from_reader(r)?))) } + TypeVariant::ScEnvMetaEntryInterfaceVersion => Ok( + Self::ScEnvMetaEntryInterfaceVersion(Box::new(serde_json::from_reader(r)?)), + ), TypeVariant::ScMetaV0 => Ok(Self::ScMetaV0(Box::new(serde_json::from_reader(r)?))), TypeVariant::ScMetaKind => Ok(Self::ScMetaKind(Box::new(serde_json::from_reader(r)?))), TypeVariant::ScMetaEntry => { @@ -60538,6 +60625,11 @@ impl Type { TypeVariant::ScEnvMetaEntry => Ok(Self::ScEnvMetaEntry(Box::new( serde::de::Deserialize::deserialize(r)?, ))), + TypeVariant::ScEnvMetaEntryInterfaceVersion => { + Ok(Self::ScEnvMetaEntryInterfaceVersion(Box::new( + serde::de::Deserialize::deserialize(r)?, + ))) + } TypeVariant::ScMetaV0 => Ok(Self::ScMetaV0(Box::new( serde::de::Deserialize::deserialize(r)?, ))), @@ -61945,6 +62037,7 @@ impl Type { Self::ConfigSettingEntry(ref v) => v.as_ref(), Self::ScEnvMetaKind(ref v) => v.as_ref(), Self::ScEnvMetaEntry(ref v) => v.as_ref(), + Self::ScEnvMetaEntryInterfaceVersion(ref v) => v.as_ref(), Self::ScMetaV0(ref v) => v.as_ref(), Self::ScMetaKind(ref v) => v.as_ref(), Self::ScMetaEntry(ref v) => v.as_ref(), @@ -62420,6 +62513,7 @@ impl Type { Self::ConfigSettingEntry(_) => "ConfigSettingEntry", Self::ScEnvMetaKind(_) => "ScEnvMetaKind", Self::ScEnvMetaEntry(_) => "ScEnvMetaEntry", + Self::ScEnvMetaEntryInterfaceVersion(_) => "ScEnvMetaEntryInterfaceVersion", Self::ScMetaV0(_) => "ScMetaV0", Self::ScMetaKind(_) => "ScMetaKind", Self::ScMetaEntry(_) => "ScMetaEntry", @@ -62880,7 +62974,7 @@ impl Type { #[must_use] #[allow(clippy::too_many_lines)] - pub const fn variants() -> [TypeVariant; 462] { + pub const fn variants() -> [TypeVariant; 463] { Self::VARIANTS } @@ -62925,6 +63019,7 @@ impl Type { Self::ConfigSettingEntry(_) => TypeVariant::ConfigSettingEntry, Self::ScEnvMetaKind(_) => TypeVariant::ScEnvMetaKind, Self::ScEnvMetaEntry(_) => TypeVariant::ScEnvMetaEntry, + Self::ScEnvMetaEntryInterfaceVersion(_) => TypeVariant::ScEnvMetaEntryInterfaceVersion, Self::ScMetaV0(_) => TypeVariant::ScMetaV0, Self::ScMetaKind(_) => TypeVariant::ScMetaKind, Self::ScMetaEntry(_) => TypeVariant::ScMetaEntry, @@ -63467,6 +63562,7 @@ impl WriteXdr for Type { Self::ConfigSettingEntry(v) => v.write_xdr(w), Self::ScEnvMetaKind(v) => v.write_xdr(w), Self::ScEnvMetaEntry(v) => v.write_xdr(w), + Self::ScEnvMetaEntryInterfaceVersion(v) => v.write_xdr(w), Self::ScMetaV0(v) => v.write_xdr(w), Self::ScMetaKind(v) => v.write_xdr(w), Self::ScMetaEntry(v) => v.write_xdr(w), diff --git a/xdr/curr b/xdr/curr index 4ec28d95..2a23ba55 160000 --- a/xdr/curr +++ b/xdr/curr @@ -1 +1 @@ -Subproject commit 4ec28d95dd84b109253e22b151314478d6f00522 +Subproject commit 2a23ba55af22f7e766b97e04a2581a3e837e6c43 diff --git a/xdr/curr-version b/xdr/curr-version index 20860efd..22d8ef96 100644 --- a/xdr/curr-version +++ b/xdr/curr-version @@ -1 +1 @@ -4ec28d95dd84b109253e22b151314478d6f00522 \ No newline at end of file +2a23ba55af22f7e766b97e04a2581a3e837e6c43 \ No newline at end of file diff --git a/xdr/next b/xdr/next index 86b4ff57..a915787e 160000 --- a/xdr/next +++ b/xdr/next @@ -1 +1 @@ -Subproject commit 86b4ff573c3e9a475f9280b97645cc75e2c75b6e +Subproject commit a915787e5a9328f1f2c1a8773c6a4c0b1ec8640b diff --git a/xdr/next-version b/xdr/next-version index a1789d6e..0dbcab4b 100644 --- a/xdr/next-version +++ b/xdr/next-version @@ -1 +1 @@ -86b4ff573c3e9a475f9280b97645cc75e2c75b6e \ No newline at end of file +a915787e5a9328f1f2c1a8773c6a4c0b1ec8640b \ No newline at end of file