Home | History | Annotate | Download | only in SemaTemplate
      1 // RUN: %clang_cc1 -fsyntax-only -verify %s
      2 
      3 struct mystruct {
      4   int  member;
      5 };
      6 
      7 template <int i>
      8 int foo() {
      9   mystruct s[1];
     10   return s->member;
     11 }
     12 
     13 int main() {
     14   foo<1>();
     15 }
     16 
     17 // PR7405
     18 struct hb_sanitize_context_t {
     19   int start;
     20 };
     21 template <typename Type> static bool sanitize() {
     22   hb_sanitize_context_t c[1];
     23   return !c->start;
     24 }
     25 bool closure = sanitize<int>();
     26