blob: 7ebb72f54a0581843974329a579f2b80fc60e8f7 [file] [log] [blame]
John McCalle71d60d2010-10-05 20:48:15 +00001// RUN: %clang-cc1 %s -fexceptions
2
3// Reduced from a crash on boost::interprocess's node_allocator_test.cpp.
4namespace test0 {
5 struct A { A(); ~A(); };
6 struct V { V(const A &a = A()); ~V(); };
7
8 template<int X> int vector_test()
9 {
10 A process_name;
11 try {
12 A segment;
13
14 V *stdvector = new V();
15
16 int x = 5, y = 7;
17 if(x == y) return 1;
18 }
19 catch(int ex){
20 return 1;
21 }
22 return 0;
23}
24
25int main ()
26{
27 return vector_test<0>();
28}
29}