Skip to content

Conversation

@tnull
Copy link
Collaborator

@tnull tnull commented Feb 5, 2024

.. this allows us the retrieve a Config prepopulated with default values in bindings (where Default::default() isn't available), even if it includes complex structures for which we can't set default values in the UDL file.

.. this allows us the retrieve a `Config` prepopulated with default values in
bindings (where `Default::default()` isn't available), even if it
includes complex structures for which we can't set default values in the
UDL file.
@tnull tnull requested a review from G8XSU February 5, 2024 11:47
///
/// This is mostly meant for use in bindings, in Rust this is synonymous with
/// [`Config::default()`].
pub fn default_config() -> Config {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this be "uniffi" flagged?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, good question. I debated that in my head to for a bit, I currently left it exposed in Rust too as the Rust docs are the only discoverable docs we have currently. It might be confusing if we'd only expose this in bindings.

I have no super strong opinion on this though.

@tnull tnull merged commit 6fef493 into lightningdevkit:main Feb 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants