Discussion Thread: DIP 1033--Implicit Conversion of Expressions to Delegates--Final Review

Nick Treleaven nick at geany.org
Mon Nov 23 16:00:25 UTC 2020

On Monday, 23 November 2020 at 12:55:45 UTC, Timon Gehr wrote:
> If it's at the call site, at least you can tell from the 
> function signature...

If you and all reviewers correctly detect the right overload. 
What if the programmer doesn't check the signature every time 
they use that function?

> We have @nogc. What's the point of even supporting @nogc if 
> this kind of rhetoric continues anyway?

You may still want some GC allocations, but not want a closure 
allocated. Or you simply want allocations to be obvious, because 
they can be slow.

> I'd rather have a language that is useful instead of one that 
> appeals to people with bad decision making.

How does having to write `() => ` for each argument flip a 
language from being useful to not useful?

More information about the Digitalmars-d mailing list