[ create a new paste ] login | about

Project: ncu
Link: http://ncu.codepad.org/7lCdpCxQ    [ raw code | output | fork ]

GiM - D, pasted on May 22:
1
2
3
4
5
6
7
8
9
10
11
12
13
import tango.io.Stdout;

template Foo() { int x = 9; }

void main()
{
    int x = 7;
    {
        Stdout.formatln ("{}", x);
        mixin Foo;
        Stdout.formatln ("{}", x);
    }
}


Output:
1
2
7
9


Create a new paste based on this one


Comments: