Skip to content

Commit eff4d77

Browse files
committed
Avoid collision in Bolt11Invoice::description
When exporting `Display` to bindings, Swift will add a `description` method to the respective object. Unfortunately, this collides with `Bolt11Invoice::description`, which we therefore rename to `Bolt11Invoice::invoice_description`.
1 parent a2d4c1e commit eff4d77

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

bindings/ldk_node.udl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -728,7 +728,7 @@ interface Bolt11Invoice {
728728
u64 seconds_until_expiry();
729729
boolean is_expired();
730730
boolean would_expire(u64 at_time_seconds);
731-
Bolt11InvoiceDescription description();
731+
Bolt11InvoiceDescription invoice_description();
732732
u64 min_final_cltv_expiry_delta();
733733
Network network();
734734
Currency currency();

src/ffi/types.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -985,7 +985,7 @@ impl Bolt11Invoice {
985985
}
986986

987987
/// Return the description or a hash of it for longer ones
988-
pub fn description(&self) -> Bolt11InvoiceDescription {
988+
pub fn invoice_description(&self) -> Bolt11InvoiceDescription {
989989
self.inner.description().into()
990990
}
991991

0 commit comments

Comments
 (0)