2009-12-16 04:14:24 +08:00
|
|
|
// RUN: %clang_cc1 %s -fsyntax-only -verify -pedantic
|
2008-09-02 13:09:35 +08:00
|
|
|
|
|
|
|
typedef const char rchar;
|
|
|
|
int a(char* a, rchar* b) {
|
|
|
|
return a-b;
|
|
|
|
}
|
2009-01-24 03:03:35 +08:00
|
|
|
|
|
|
|
// <rdar://problem/6520707>
|
|
|
|
void f0(void (*fp)(void)) {
|
2011-06-27 16:02:19 +08:00
|
|
|
int x = fp - fp; // expected-warning{{arithmetic on pointers to the function type 'void (void)' is a GNU extension}}
|
2009-01-24 03:03:35 +08:00
|
|
|
}
|