Some piece of WAT, is that a bug or a feature ?

Rikki Cattermole via Digitalmars-d digitalmars-d at puremagic.com
Sun May 17 01:48:02 PDT 2015


On 17/05/2015 8:38 p.m., deadalnix wrote:
> So this code:
>
> void main() {
>      string outs;
>
>      void foo() {
>          outs ~= "prout !";
>      }
>
>      import std.stdio;
>      writeln(outs);
> }
>
> Obviously print an empty string.
>
> Bug or feature ?

Feature. foo is never called.


More information about the Digitalmars-d mailing list