]> git.bitcoin.ninja Git - rust-lightning/commitdiff
Re-order define_run_body macro parameters
authorJeffrey Czyz <jkczyz@gmail.com>
Thu, 16 Nov 2023 15:03:18 +0000 (09:03 -0600)
committerJeffrey Czyz <jkczyz@gmail.com>
Wed, 6 Dec 2023 20:43:39 +0000 (14:43 -0600)
Simply to avoid excessive wrapping when possible.

lightning-background-processor/src/lib.rs

index f953ba1c753750133b6e79a3cc43eb1e05c81962..fc080eee1f7c4db42788e4e4df5c5513ec1a642f 100644 (file)
@@ -273,7 +273,7 @@ macro_rules! define_run_body {
        (
                $persister: ident, $chain_monitor: ident, $process_chain_monitor_events: expr,
                $channel_manager: ident, $process_channel_manager_events: expr,
-               $gossip_sync: ident, $peer_manager: ident, $logger: ident, $scorer: ident,
+               $peer_manager: ident, $gossip_sync: ident, $logger: ident, $scorer: ident,
                $loop_exit_check: expr, $await: expr, $get_timer: expr, $timer_elapsed: expr,
                $check_slow_await: expr
        ) => { {
@@ -655,7 +655,7 @@ where
                persister, chain_monitor,
                chain_monitor.process_pending_events_async(async_event_handler).await,
                channel_manager, channel_manager.process_pending_events_async(async_event_handler).await,
-               gossip_sync, peer_manager, logger, scorer, should_break, {
+               peer_manager, gossip_sync, logger, scorer, should_break, {
                        let fut = Selector {
                                a: channel_manager.get_event_or_persistence_needed_future(),
                                b: chain_monitor.get_update_future(),
@@ -788,7 +788,7 @@ impl BackgroundProcessor {
                        define_run_body!(
                                persister, chain_monitor, chain_monitor.process_pending_events(&event_handler),
                                channel_manager, channel_manager.process_pending_events(&event_handler),
-                               gossip_sync, peer_manager, logger, scorer, stop_thread.load(Ordering::Acquire),
+                               peer_manager, gossip_sync, logger, scorer, stop_thread.load(Ordering::Acquire),
                                { Sleeper::from_two_futures(
                                        channel_manager.get_event_or_persistence_needed_future(),
                                        chain_monitor.get_update_future()