File tree Expand file tree Collapse file tree 1 file changed +2
-5
lines changed
crates/forge-runner/src/gas Expand file tree Collapse file tree 1 file changed +2
-5
lines changed Original file line number Diff line number Diff line change 11use crate :: gas:: stats:: GasStats ;
22use cheatnet:: trace_data:: { CallTrace , CallTraceNode } ;
3- use debugging:: ContractName as DebuggingContractName ;
43use debugging:: ContractsDataStore ;
54use starknet_api:: core:: { ClassHash , EntryPointSelector } ;
65use starknet_api:: execution_resources:: GasVector ;
@@ -105,10 +104,8 @@ impl SingleTestGasInfo {
105104fn get_contract_name ( contracts_data : & ContractsDataStore , class_hash : ClassHash ) -> ContractName {
106105 contracts_data
107106 . get_contract_name ( & class_hash)
108- . cloned ( )
109- . unwrap_or_else ( || DebuggingContractName ( "forked contract" . to_string ( ) ) )
110- . 0
111- . clone ( )
107+ . map_or ( "forked contract" , |name| name. 0 . as_str ( ) )
108+ . to_string ( )
112109}
113110
114111fn get_selector ( contracts_data : & ContractsDataStore , selector : EntryPointSelector ) -> Selector {
You can’t perform that action at this time.
0 commit comments