1 // RUN: %clang_cc1 -fsyntax-only -Wno-deprecated-writable-strings -verify %s
2 // RUN: %clang_cc1 -fsyntax-only -fwritable-strings -verify %s
3 // RUN: %clang_cc1 -fsyntax-only -Wno-write-strings -verify %s
4 // RUN: %clang_cc1 -fsyntax-only -Werror=c++11-compat -verify %s -DERROR
5 // rdar://8827606
6 
7 char *fun(void)
8 {
9    return "foo";
10 #ifdef ERROR
11    // expected-error@-2 {{deprecated}}
12 #endif
13 }
14 
15 void test(bool b)
16 {
17   ++b; // expected-warning {{incrementing expression of type bool is deprecated}}
18 }
19