auto: useful, annoying or bad practice?
H. S. Teoh
hsteoh at quickfur.ath.cx
Fri May 11 19:06:43 UTC 2018
On Fri, May 11, 2018 at 06:56:13PM +0000, Chris M. via Digitalmars-d wrote:
> On Friday, 11 May 2018 at 18:44:25 UTC, H. S. Teoh wrote:
> > On Fri, May 11, 2018 at 04:57:05PM +0000, Mark via Digitalmars-d wrote:
> > > [...]
> >
> > This makes me wonder if it might be useful to have return-type
> > constraints. A kind of static out-contract? Something that's part
> > of the function declaration, that ensures that the return type
> > satisfies certain properties.
> >
> > [...]
>
> Coincidentally, over in Rust...
>
> https://blog.rust-lang.org/2018/05/10/Rust-1.26.html
Great minds think alike. :-D
(Or fools seldom differ?)
T
--
The problem with the world is that everybody else is stupid.
More information about the Digitalmars-d
mailing list