summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gdc.test/fail_compilation/fail18985.d
blob: 830a6792ad2dda522e0d54c05c5ffd6bb7a02b30 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/*
TEST_OUTPUT:
---
fail_compilation/fail18985.d(16): Error: `foo` is not a scalar, it is a `object.Object`
fail_compilation/fail18985.d(17): Error: `bar` is not a scalar, it is a `shared(Object)`
---
*/

// https://issues.dlang.org/show_bug.cgi?id=18985

Object foo;
shared Object bar;

void main()
{
    foo += 1;
    bar += 1;
}