File tree Expand file tree Collapse file tree
crates/cairo-lang-sierra-generator/src Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -94,7 +94,7 @@ edition = "2024"
9494license = " Apache-2.0"
9595license-file = " LICENSE"
9696repository = " https://github.com/starkware-libs/cairo/"
97- rust-version = " 1.86 "
97+ rust-version = " 1.94 "
9898version = " 2.18.0"
9999
100100[workspace .dependencies ]
Original file line number Diff line number Diff line change @@ -83,12 +83,11 @@ fn get_function_ap_change_and_code<'db>(
8383
8484 // If the function starts with `revoke_ap_tracking` then we can avoid
8585 // the first `disable_ap_tracking`.
86- if let Some ( lowering:: Statement :: Call ( call_stmt) ) = root_block. statements . first ( ) {
87- if get_concrete_libfunc_id ( db, call_stmt. function , false ) . 1
86+ if let Some ( lowering:: Statement :: Call ( call_stmt) ) = root_block. statements . first ( )
87+ && get_concrete_libfunc_id ( db, call_stmt. function , false ) . 1
8888 == revoke_ap_tracking_libfunc_id ( db)
89- {
90- context. set_ap_tracking ( false ) ;
91- }
89+ {
90+ context. set_ap_tracking ( false ) ;
9291 }
9392
9493 // Generate a label for the function's body.
Original file line number Diff line number Diff line change @@ -443,10 +443,10 @@ pub fn get_dummy_program_for_size_estimation(
443443 let mut functions = vec ! [ function] ;
444444
445445 for statement in & function. body {
446- if let Some ( function_id) = try_get_function_with_body_id ( db, statement) {
447- if processed_function_ids. insert ( function_id) {
448- functions . push ( db . priv_get_dummy_function ( function_id ) ? ) ;
449- }
446+ if let Some ( function_id) = try_get_function_with_body_id ( db, statement)
447+ && processed_function_ids. insert ( function_id)
448+ {
449+ functions . push ( db . priv_get_dummy_function ( function_id ) ? ) ;
450450 }
451451 }
452452 // Since we are not interested in the locations, we can remove them from the statements.
Original file line number Diff line number Diff line change @@ -455,10 +455,11 @@ impl<'db> AddStoreVariableStatements<'db> {
455455 fn store_all_possibly_lost_variables ( & mut self , state : & mut VariablesState ) {
456456 self . store_variables_as_locals ( state) ;
457457 for ( var, var_state) in state. variables . iter_mut ( ) {
458- if let VarState :: Deferred { info } = var_state {
459- if info. kind != DeferredOutputKind :: Const && self . duplicated_vars . contains ( var) {
460- * var_state = self . store_deferred ( & mut state. known_stack , var, & info. ty ) ;
461- }
458+ if let VarState :: Deferred { info } = var_state
459+ && info. kind != DeferredOutputKind :: Const
460+ && self . duplicated_vars . contains ( var)
461+ {
462+ * var_state = self . store_deferred ( & mut state. known_stack , var, & info. ty ) ;
462463 }
463464 }
464465 }
Original file line number Diff line number Diff line change @@ -387,12 +387,11 @@ fn run_e2e_test(
387387
388388 // Handle test_data if specified.
389389 // This runs AFTER sierra/casm generation, so compilation outputs are always verified first.
390- if let Some ( test_data) = params. test_data {
391- if let Err ( e) =
390+ if let Some ( test_data) = params. test_data
391+ && let Err ( e) =
392392 run_and_validate_test_data ( sierra_program, test_data, params. add_withdraw_gas )
393- {
394- return TestRunnerResult { outputs : res, error : Some ( e) } ;
395- }
393+ {
394+ return TestRunnerResult { outputs : res, error : Some ( e) } ;
396395 }
397396
398397 TestRunnerResult :: success ( res)
You can’t perform that action at this time.
0 commit comments