1 // RUN: %clang_cc1 -std=c++11 -fsyntax-only -verify %s
2 
3 void f0() {
4   int &ir = { 17 }; // expected-error{{reference to type 'int' cannot bind to an initializer list}}
5 }
6 
7 namespace PR12453 {
8   template<typename T>
9   void f(int i) {
10     T x{i}; // expected-error{{non-constant-expression cannot be narrowed from type 'int' to 'float' in initializer list}} \
11     // expected-note{{override this message by inserting an explicit cast}}
12     T y{i}; // expected-error{{non-constant-expression cannot be narrowed from type 'int' to 'float' in initializer list}} \
13     // expected-note{{override this message by inserting an explicit cast}}
14   }
15 
16   template void f<float>(int); // expected-note{{in instantiation of function template specialization 'PR12453::f<float>' requested here}}
17 }
18