aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gdc.test/runnable/bug5.d
blob: cbb4dcfee40895390c1cbd00befb3756179e7914 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// REQUIRED_ARGS: -w

class F { }

int test1() {
    scope F f = new F(); // comment out and warning goes away
    return 0;
}

int test2() { // no return at end of function
    try {
        return 0;
    } finally { }
}

void main()
{
    test1();
    test2();
}