Ilya Biryukov | 95f0d32 | 2017-12-28 13:05:46 +0000 | [diff] [blame] | 1 | // RUN: env CINDEXTEST_SKIP_FUNCTION_BODIES=1 c-index-test -test-load-source all %s 2>&1 \ |
2 | // RUN: | FileCheck --implicit-check-not "error:" %s | ||||
3 | |||||
4 | |||||
5 | template <class T> | ||||
6 | struct Foo { | ||||
7 | template <class = int> | ||||
8 | Foo(int &a) : a(a) { | ||||
9 | } | ||||
10 | |||||
11 | int &a; | ||||
12 | }; | ||||
13 | |||||
14 | |||||
15 | int bar = Foo<int>(bar).a + Foo<int>(bar).a; | ||||
16 | // CHECK-NOT: error: constructor for 'Foo<int>' must explicitly initialize the reference |