blob: 6b410018f4b724867559a987aeb0cbe5749be4e6 [file] [log] [blame]
Daniel Dunbard7d5f022009-03-24 02:24:46 +00001// RUN: clang-cc %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