comparison clang/test/PCH/chain-invalid-code.cpp @ 150:1d019706d866

LLVM10
author anatofuz
date Thu, 13 Feb 2020 15:10:13 +0900
parents
children
comparison
equal deleted inserted replaced
147:c2174574ed3a 150:1d019706d866
1 // RUN: %clang_cc1 -fsyntax-only %s -chain-include %s -Wuninitialized -Wunused -verify
2
3 // Make sure there is no crash.
4
5 #ifndef HEADER
6 #define HEADER
7
8 #include "non-existent-header.h"
9
10 class A {
11 public:
12 ~A();
13 };
14
15 class ForwardCls;
16 struct B {
17 ForwardCls f;
18 A a;
19 };
20
21 #else
22
23 static void test() {
24 int x; // expected-warning {{unused}}
25 B b;
26 }
27
28 #endif