digitalmars.D - Automatic type expansion of functions to delegates?
- Andrew Pennebaker (3/3) Dec 08 2018 Hey, do you think it would be possible for D to automatically
- Adam D. Ruppe (6/9) Dec 08 2018 It is pretty simple to just call toDelegate to do that
Hey, do you think it would be possible for D to automatically expand more types, such as promoting functions to delegates? This would save us from having to write some boilerplate code.
Dec 08 2018
On Sunday, 9 December 2018 at 02:02:51 UTC, Andrew Pennebaker wrote:Hey, do you think it would be possible for D to automatically expand more types, such as promoting functions to delegates? This would save us from having to write some boilerplate code.It is pretty simple to just call toDelegate to do that conversion. D is unlikely to get more automatic conversions going forward, especially of built-ins. http://dpldocs.info/experimental-docs/std.functional.toDelegate.html
Dec 08 2018