Skip to content

Commit c691cf8

Browse files
committed
Temporarily allow some unused dual-funding code
1 parent 35bcd5d commit c691cf8

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

lightning/src/ln/channel.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1127,6 +1127,7 @@ impl_writeable_tlv_based!(PendingChannelMonitorUpdate, {
11271127
pub(super) enum ChannelPhase<SP: Deref> where SP::Target: SignerProvider {
11281128
UnfundedOutboundV1(OutboundV1Channel<SP>),
11291129
UnfundedInboundV1(InboundV1Channel<SP>),
1130+
#[allow(dead_code)] // TODO(dual_funding): Remove once creating V2 channels is enabled.
11301131
UnfundedOutboundV2(OutboundV2Channel<SP>),
11311132
UnfundedInboundV2(InboundV2Channel<SP>),
11321133
Funded(Channel<SP>),
@@ -4089,6 +4090,7 @@ pub(super) fn calculate_our_funding_satoshis(
40894090
pub(super) struct DualFundingChannelContext {
40904091
/// The amount in satoshis we will be contributing to the channel.
40914092
pub our_funding_satoshis: u64,
4093+
#[allow(dead_code)] // TODO(dual_funding): Remove once contribution to V2 channels is enabled.
40924094
/// The amount in satoshis our counterparty will be contributing to the channel.
40934095
pub their_funding_satoshis: Option<u64>,
40944096
/// The funding transaction locktime suggested by the initiator. If set by us, it is always set
@@ -4108,6 +4110,7 @@ pub(super) struct DualFundingChannelContext {
41084110
// Counterparty designates channel data owned by the another channel participant entity.
41094111
pub(super) struct Channel<SP: Deref> where SP::Target: SignerProvider {
41104112
pub context: ChannelContext<SP>,
4113+
#[allow(dead_code)] // TODO(dual_funding): Remove once contribution to V2 channels is enabled.
41114114
pub dual_funding_channel_context: Option<DualFundingChannelContext>,
41124115
/// The current interactive transaction construction session under negotiation.
41134116
pub interactive_tx_constructor: Option<InteractiveTxConstructor>,
@@ -8605,6 +8608,7 @@ pub(super) struct OutboundV2Channel<SP: Deref> where SP::Target: SignerProvider
86058608
}
86068609

86078610
impl<SP: Deref> OutboundV2Channel<SP> where SP::Target: SignerProvider {
8611+
#[allow(dead_code)] // TODO(dual_funding): Remove once creating V2 channels is enabled.
86088612
pub fn new<ES: Deref, F: Deref, L: Deref>(
86098613
fee_estimator: &LowerBoundedFeeEstimator<F>, entropy_source: &ES, signer_provider: &SP,
86108614
counterparty_node_id: PublicKey, their_features: &InitFeatures, funding_satoshis: u64,
@@ -8927,6 +8931,7 @@ impl<SP: Deref> InboundV2Channel<SP> where SP::Target: SignerProvider {
89278931
///
89288932
/// [`msgs::AcceptChannelV2`]: crate::ln::msgs::AcceptChannelV2
89298933
#[cfg(test)]
8934+
#[allow(dead_code)] // TODO(dual_funding): Remove once contribution to V2 channels is enabled.
89308935
pub fn get_accept_channel_v2_message(&self) -> msgs::AcceptChannelV2 {
89318936
self.generate_accept_channel_v2_message()
89328937
}

lightning/src/ln/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ mod async_signer_tests;
8888
#[cfg(test)]
8989
#[allow(unused_mut)]
9090
mod offers_tests;
91+
#[allow(dead_code)] // TODO(dual_funding): Remove once contribution to V2 channels is enabled.
9192
pub(crate) mod interactivetxs;
9293

9394
pub use self::peer_channel_encryptor::LN_MAX_MSG_LEN;

0 commit comments

Comments
 (0)