aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gdc.test/runnable/link10920.d
blob: 29f3a47f44f77549e7cd2e0895ff9e26e356df4e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
// PERMUTE_ARGS: -version=A

// It's imported but won't be linked.
import imports.link10920a;

void main()
{
    BitArray ba;
    version(A)
    {
        // Run semantic3 of BitArray.toString()
        // before the FormatSpec instantiation in main().
        pragma(msg, typeof(ba.toString()));
    }

    // The instance codegen should be run always, unrelated with -version=A.
    FormatSpec!char fs;
    fs.func();
}