estebank / makeit

Zero-overhead type-safe builder pattern `derive` macro for your Rust structs
223 stars 11 forks source link

Do not emit the parentheses wrapping the default value with `#[default(...)]` #2

Closed ChayimFriedman2 closed 2 years ago

ChayimFriedman2 commented 2 years ago

This fixes the compiler suggestions; see rust-lang/rust#94074.

Technically this is a breaking change - previously, because of the parentheses, you could actually pass a tuple as the default value without wrapping it in parentheses - e.g. #[default(1, 1)]. Now you need to do #[default((1, 1))]. However, I don't think someone relied on this, as it looks like the wrong behavior.

lilyball commented 2 years ago

It looks like makeit 0.1.2 was never published after this change?