X-Git-Url: https://git.ozlabs.org/?p=ccan;a=blobdiff_plain;f=ccan%2Fcast%2Fcast.h;h=d54209170d73de84343e3dfb6609a17da982737a;hp=dfb95b59772611bf53582b4b4ef132970104a829;hb=74257cee33ae3033f961d5f22a0313b8cb1b18d4;hpb=1313203b72656e8480805c7688c187d274fdceeb diff --git a/ccan/cast/cast.h b/ccan/cast/cast.h index dfb95b59..d5420917 100644 --- a/ccan/cast/cast.h +++ b/ccan/cast/cast.h @@ -1,3 +1,4 @@ +/* Licensed under LGPLv3+ - see LICENSE file for details */ #ifndef CCAN_CAST_H #define CCAN_CAST_H #include "config.h" @@ -122,11 +123,8 @@ #else #define cast_sign_compatible(type, expr) \ (sizeof(*(type)0) == 1 && sizeof(*(expr)) == 1) -#define cast_const_compat1(expr, type) \ - (sizeof(*(expr)) == sizeof(*(type)0)) -#define cast_const_compat2(expr, type) \ - (sizeof(**(expr)) == sizeof(**(type)0)) -#define cast_const_compat3(expr, type) \ - (sizeof(***(expr)) == sizeof(***(type)0)) +#define cast_const_compat1(expr, type) (1) +#define cast_const_compat2(expr, type) (1) +#define cast_const_compat3(expr, type) (1) #endif #endif /* CCAN_CAST_H */