Closed wcarmon closed 7 months ago
Possible duplicate of https://github.com/colin-kiegel/rust-derive-builder/issues/170
Perhaps this is more of a documentation issue (as opposed to code change)
I don't know that a documentation change is needed here; Rust has a canonical way to do this (discussed in the linked comment), it's not something that many people using builders seem to need to do, and the crate doesn't provide any special support for it.
Docs would save you from having the same discussion repeatedly.
From the issue history, it looks like you've had to respond to this several times.
I’d be happy to review a PR with a proposed docs amendment on it.
What's the best way to go from an instance to a new builder?
Use case:
given a struct with 30 fields, create a new struct with one field changed and go thru the validation again.
In the old world (read Java), we would do something like
foo1.toBuilder().field(newValue).build()
https://projectlombok.org/features/Builder