On 19/11/2020 1:11 PM, Dibyendu Majumdar wrote:
On Thursday, 19 November 2020 at 00:08:59 UTC, Adam D. Ruppe wrote:
On Thursday, 19 November 2020 at 00:07:12 UTC, Dibyendu Majumdar wrote:
int function() fp = test;

This tries to *call* the function test and assign its return value to fp.


Really? why does it do that?

You don't need the brackets to call a function (and with a little help from UFCS):

void main() {
        import std.stdio;
        
        "Hello!".writeln;
        writeln;
}

Reply via email to