Puzzled by this behavior

Ola Fosheim Grøstad ola.fosheim.grostad at gmail.com
Wed Jun 1 14:08:24 UTC 2022


On Wednesday, 1 June 2022 at 13:48:48 UTC, Timon Gehr wrote:
> There is no need at all to solve this with function pointers 
> the way you describe, just allow forward references and 
> overloading between local functions that are declared next to 
> each other.

The most sensible is to let local functions be syntax sugar for 
lambdas. Just make delegate variables assign-once and 
initialize-before-use.

The core D semantics can be made quite simple with a bit of 
effort. I hope SDC thinks about how to boil the D semantics down 
to a bare minimum…



More information about the Digitalmars-d mailing list