diff options
author | Kent Overstreet <kent.overstreet@gmail.com> | 2017-10-05 13:42:19 -0800 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@gmail.com> | 2017-10-08 10:25:36 -0800 |
commit | bf8c59996b3fb2a940827d12438a9e18eca6db4c (patch) | |
tree | 86366ab663beeeeec3554ce3407159aaacd70714 /ccan/array_size/test/compile_fail-function-param.c | |
parent | 85ee972555948337bb1a58f0702a4da95db6758f (diff) |
Update for new superblock options; makefile improvements
Diffstat (limited to 'ccan/array_size/test/compile_fail-function-param.c')
-rw-r--r-- | ccan/array_size/test/compile_fail-function-param.c | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/ccan/array_size/test/compile_fail-function-param.c b/ccan/array_size/test/compile_fail-function-param.c deleted file mode 100644 index 48697e04..00000000 --- a/ccan/array_size/test/compile_fail-function-param.c +++ /dev/null @@ -1,24 +0,0 @@ -#include <ccan/array_size/array_size.h> -#include <stdlib.h> - -struct foo { - unsigned int a, b; -}; - -int check_parameter(const struct foo *array); -int check_parameter(const struct foo *array) -{ -#ifdef FAIL - return (ARRAY_SIZE(array) == 4); -#if !HAVE_TYPEOF || !HAVE_BUILTIN_TYPES_COMPATIBLE_P -#error "Unfortunately we don't fail if _array_size_chk is a noop." -#endif -#else - return sizeof(array) == 4 * sizeof(struct foo); -#endif -} - -int main(int argc, char *argv[]) -{ - return check_parameter(NULL); -} |