Discussion Thread: DIP 1043--Shortened Method Syntax--Final Review
Paul Backus
snarwin at gmail.com
Fri Jun 17 14:14:10 UTC 2022
On Friday, 17 June 2022 at 13:17:37 UTC, Nick Treleaven wrote:
>
> It could also allow skipping some fields and support custom
> initialization of those fields using a function literal:
>
[...]
>
> And ddoc works for a documented template mixin declaration
> containing a documented constructor.
Unfortunately you pretty much have to use a string mixin, to
avoid [issue 3332][1].
For a more sophisticated implementation, [`GenerateThis`][2] from
the [`boilerplate` package][3] is probably the way to go.
[1]: https://issues.dlang.org/show_bug.cgi?id=3332
[2]:
https://boilerplate.dpldocs.info/v1.7.7/boilerplate.constructor.GenerateThis.html
[3]: https://code.dlang.org/packages/boilerplate
More information about the Digitalmars-d
mailing list