blob: c1ff8e1d7b1f328bfff6781fdf8fa7168cd29d80 [file] [log] [blame]
Daniel Dunbara5728872009-12-15 20:14:24 +00001// RUN: %clang_cc1 %s -verify -pedantic
Chris Lattnerbfe639e2008-01-03 22:56:36 +00002typedef int unary_int_func(int arg);
3unary_int_func *func;
4
5unary_int_func *set_func(void *p) {
6 func = p; // expected-warning {{converts between void* and function pointer}}
7 p = func; // expected-warning {{converts between void* and function pointer}}
8
9 return p; // expected-warning {{converts between void* and function pointer}}
10}
11