-
Notifications
You must be signed in to change notification settings - Fork 358
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
Make builder pattern more practical #90
Conversation
It is confusing to have |
@nesteruk Changed this and a little bit more 🙂 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, modulo the comment below
This example does not seemed to be explaining much, maybe we could have a real-life example or an explanation on why it needs to be constructed this way rather than just specifying the struct directly? |
5460fdc
to
60cd1b0
Compare
@pickfire Hmm, changed it a little bit up. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The indentation seemed off, should be 4 spaces rather than 2 spaces.
👷♀️ Replace fmt::Display by #[derive(Debug)] 👷♀️ Rename FooBuilder to just Builder 👷 Set type for Foo-instance 👷 Change finish(...) to build(...) 👷 Rename FooBuilder artifacts to Builder 👷 Change indentation from 2 spaces to 4 spaces 👷 Rename builder_bar to bar 👷 Change finish(...) to build(...)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. I think it would be good to have one of the maintainer to check this though.
@tgotwig Hey, thank you for the PR. Could you please rebase on |
@simonsan Sure, will do! 😃 |
Sorry, haven't seen that there is no addition to summary or anything needed. So I could do it myself. ;-) It's fine then. |
I am dismissing lambda-fairy review because it requested changes on something that was resolved. If I don't do this we can't merge this. If I am making a mistake please tell me!
@MarcoIeni You also want to look over it again? |
Thanks! :-) |
Cool! 😊🚀 |
https://github.com/TGotwig/patterns/blob/patch-1/patterns/builder.md