Skip to content
This repository has been archived by the owner on Jul 22, 2024. It is now read-only.

Commit

Permalink
update core contract_address
Browse files Browse the repository at this point in the history
  • Loading branch information
edg-l committed Jun 5, 2024
1 parent d62144c commit 9784e74
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/core/contract_address/casm_contract_address.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use crate::core::errors::contract_address_errors::ContractAddressError;
use crate::services::api::contract_classes::deprecated_contract_class::EntryPointType;
use cairo_lang_starknet::casm_contract_class::{CasmContractClass, CasmContractEntryPoint};
use cairo_lang_starknet_classes::casm_contract_class::{CasmContractClass, CasmContractEntryPoint};
use cairo_vm::Felt252;
use starknet_crypto::{poseidon_hash_many, FieldElement};

Expand Down
6 changes: 1 addition & 5 deletions src/core/contract_address/deprecated_contract_address.rs
Original file line number Diff line number Diff line change
Expand Up @@ -326,11 +326,7 @@ pub fn compute_deprecated_class_hash(

for builtin_name in contract_class.program().iter_builtins() {
builtin_list_vec.push(Felt252::from_bytes_be_slice(
builtin_name
.name()
.strip_suffix("_builtin")
.ok_or(ContractAddressError::BuiltinSuffix)?
.as_bytes(),
builtin_name.to_str().as_bytes(),
));
}

Expand Down
4 changes: 2 additions & 2 deletions src/core/contract_address/sierra_contract_address.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use crate::{core::errors::contract_address_errors::ContractAddressError, EntryPointType};
use cairo_lang_starknet::{
contract::starknet_keccak,
use cairo_lang_starknet_classes::{
contract_class::{ContractClass as SierraContractClass, ContractEntryPoint},
keccak::starknet_keccak,
};
use cairo_vm::Felt252;
use serde_json::ser::Formatter;
Expand Down

0 comments on commit 9784e74

Please sign in to comment.