Skip to content

Commit

Permalink
chore(starknet_api): add sierra version utils (#2828)
Browse files Browse the repository at this point in the history
  • Loading branch information
AvivYossef-starkware authored Dec 19, 2024
1 parent 5aa3cf8 commit 1dfd8a7
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions crates/starknet_api/src/contract_class.rs
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,13 @@ impl FromStr for SierraVersion {
}
}

#[allow(dead_code)]
impl From<(u64, u64, u64)> for SierraVersion {
fn from((major, minor, patch): (u64, u64, u64)) -> Self {
Self::new(major, minor, patch)
}
}

/// All relevant information about a declared contract class, including the compiled contract class
/// and other parameters derived from the original declare transaction required for billing.
#[derive(Clone, Debug, Deserialize, Eq, PartialEq, Serialize)]
Expand Down

0 comments on commit 1dfd8a7

Please sign in to comment.