That second feature sounds really neat. I'd always wished Go had implemented something like this, even if just for numeric types.
Re:My Vision of D’s Future
by cppforlife on Tuesday October 15, 2019 @05:10PM
(#21263830)
just use a wrong type (bool lets say), and check out go compilation error. it will tell you what type it wants.
Oh, and you can also use type deductions for function declarations! Just make it a template and let D figure out for you what type you want, or use typeof to record the type you want and use that typename in your function declaration.