Skip to content

Commit

Permalink
feat(sui-sdk-types): add From<StructTag> for TypeTag (#77)
Browse files Browse the repository at this point in the history
Closes #73
  • Loading branch information
unmaykr-aftermath authored Dec 19, 2024
1 parent e0d4557 commit 975b425
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions crates/sui-sdk-types/src/types/type_tag/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,12 @@ impl std::str::FromStr for TypeTag {
}
}

impl From<StructTag> for TypeTag {
fn from(value: StructTag) -> Self {
Self::Struct(Box::new(value))
}
}

#[derive(Clone, Debug, PartialEq, Eq, PartialOrd, Ord)]
pub struct TypeParseError {
source: String,
Expand Down

0 comments on commit 975b425

Please sign in to comment.