From: Elias Rohrer Date: Sat, 21 Sep 2024 05:21:39 +0000 (+0900) Subject: Update `lightning-transaction-sync` to use macros crate X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=commitdiff_plain;h=99ae425cad6f509abb7dc631f62f4f34735e3dc1;p=rust-lightning Update `lightning-transaction-sync` to use macros crate --- diff --git a/lightning-transaction-sync/Cargo.toml b/lightning-transaction-sync/Cargo.toml index 34105ea3e..34ddfec6f 100644 --- a/lightning-transaction-sync/Cargo.toml +++ b/lightning-transaction-sync/Cargo.toml @@ -24,8 +24,8 @@ async-interface = [] [dependencies] lightning = { version = "0.0.124", path = "../lightning", default-features = false, features = ["std"] } +lightning-macros = { version = "0.1", path = "../lightning-macros", default-features = false } bitcoin = { version = "0.32.2", default-features = false } -bdk-macros = "0.6" futures = { version = "0.3", optional = true } esplora-client = { version = "0.9", default-features = false, optional = true } electrum-client = { version = "0.21.0", optional = true } diff --git a/lightning-transaction-sync/src/esplora.rs b/lightning-transaction-sync/src/esplora.rs index 8b8b39cfb..a191260bc 100644 --- a/lightning-transaction-sync/src/esplora.rs +++ b/lightning-transaction-sync/src/esplora.rs @@ -13,6 +13,8 @@ use lightning::chain::{Confirm, Filter}; use lightning::util::logger::Logger; use lightning::{log_debug, log_error, log_trace}; +use lightning_macros::{maybe_async, maybe_await}; + use bitcoin::{BlockHash, Script, Txid}; #[cfg(not(feature = "async-interface"))] diff --git a/lightning-transaction-sync/src/lib.rs b/lightning-transaction-sync/src/lib.rs index 9c6831cef..19ebe007e 100644 --- a/lightning-transaction-sync/src/lib.rs +++ b/lightning-transaction-sync/src/lib.rs @@ -71,10 +71,6 @@ #![deny(unsafe_code)] #![cfg_attr(docsrs, feature(doc_auto_cfg))] -#[cfg(any(feature = "esplora-blocking", feature = "esplora-async"))] -#[macro_use] -extern crate bdk_macros; - #[cfg(any(feature = "esplora-blocking", feature = "esplora-async"))] mod esplora; diff --git a/lightning-transaction-sync/tests/integration_tests.rs b/lightning-transaction-sync/tests/integration_tests.rs index c887b2be0..0a6f40b09 100644 --- a/lightning-transaction-sync/tests/integration_tests.rs +++ b/lightning-transaction-sync/tests/integration_tests.rs @@ -11,7 +11,8 @@ use lightning_transaction_sync::ElectrumSyncClient; #[cfg(any(feature = "esplora-blocking", feature = "esplora-async"))] use lightning_transaction_sync::EsploraSyncClient; -use bdk_macros::maybe_await; +use lightning_macros::maybe_await; + use bitcoin::block::Header; use bitcoin::constants::genesis_block; use bitcoin::network::Network;