Skip to content

Commit ee7306f

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 8c9a484 commit ee7306f

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/uniffi_types.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,7 @@ impl Bolt11Invoice {
531531
}
532532

533533
/// Return the description or a hash of it for longer ones
534-
pub fn description(&self) -> Bolt11InvoiceDescription {
534+
pub fn invoice_description(&self) -> Bolt11InvoiceDescription {
535535
self.inner.description().into()
536536
}
537537

0 commit comments

Comments
 (0)