blob: 29c06f7cc797ddd8a13b316498fdcd10897c74a6 [file] [log] [blame]
Alex Lorenz00aee432017-03-22 10:04:48 +00001// RUN: %clang_cc1 -std=c++11 -emit-pch %s -o %t
2// RUN: %clang_cc1 -std=c++11 -include-pch %t -verify %s
3
4#ifndef HEADER_INCLUDED
5
6#define HEADER_INCLUDED
7
8template<typename T, int N>
9using vec = T __attribute__((ext_vector_type(N)));
10
11#else
12
13void test() {
14 vec<float, 2> a; // expected-error@-5 {{zero vector size}}
15 vec<float, 0> b; // expected-note {{in instantiation of template type alias 'vec' requested here}}
16}
17
18#endif