Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce #[derive(New)] for deriving the new() method #146

Open
Veetaha opened this issue Sep 21, 2024 · 0 comments
Open

Introduce #[derive(New)] for deriving the new() method #146

Veetaha opened this issue Sep 21, 2024 · 0 comments
Labels
design needed The feature requires more design effort feature request A new feature is requested

Comments

@Veetaha
Copy link
Collaborator

Veetaha commented Sep 21, 2024

This is based on the issue #24

Once we have a feature-complete builder derive feature we may add a feature to derive the method new() with positional parameters for the structs.

This will effectively be our wheel that reimplements the features from the derive-new crate.

Note that I'm not yet ready to invest effort into the design of this feature yet. It requires studying the prior art of the derive-new crate first and then determining how this can be integrated into bon, how this may interact with the builder feature etc. It's a big design effort, that I'd rather postpone to the time when the builder derives/macros are feature complete.

A note for the community from the maintainers

Please vote on this issue by adding a 👍 reaction to help the maintainers with prioritizing it. You may add a comment describing your real use case related to this issue for us to better understand the problem domain.

@Veetaha Veetaha added design needed The feature requires more design effort feature request A new feature is requested labels Sep 21, 2024
@Veetaha Veetaha changed the title Macro for deriving the new() method Introduce a macro for deriving the new() method Nov 10, 2024
@Veetaha Veetaha changed the title Introduce a macro for deriving the new() method Introduce #[derive(New)] for deriving the new() method Nov 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
design needed The feature requires more design effort feature request A new feature is requested
Projects
None yet
Development

No branches or pull requests

1 participant