[prev in list] [next in list] [prev in thread] [next in thread]
List: busybox
Subject: Re: [PATCH] Remove 'BUG_const_mismatch', locally defined but not used.
From: Denys Vlasenko <vda.linux () googlemail ! com>
Date: 2014-02-03 2:26:40
Message-ID: CAK1hOcO_NQSzEmSuWLW3pq3wqmLj7zZvUUVEu+QiDOEHc4Es+A () mail ! gmail ! com
[Download RAW message or body]
On Sun, Feb 2, 2014 at 10:21 AM, Cristian Ionescu-Idbohrn
<cristian.ionescu-idbohrn@axis.com> wrote:
> coreutils/catv.c:32:15: warning: typedef 'BUG_const_mismatch' locally defined but \
> not used [-Wunused-local-typedefs] typedef char BUG_const_mismatch[
> ^
>
> Signed-off-by: Cristian Ionescu-Idbohrn <cristian.ionescu-idbohrn@axis.com>
> ---
> coreutils/catv.c | 4 ----
> 1 file changed, 4 deletions(-)
>
> diff --git a/coreutils/catv.c b/coreutils/catv.c
> index e3499c5..3846aea 100644
> --- a/coreutils/catv.c
> +++ b/coreutils/catv.c
> @@ -29,10 +29,6 @@ int catv_main(int argc UNUSED_PARAM, char **argv)
> #define CATV_OPT_e (1<<0)
> #define CATV_OPT_t (1<<1)
> #define CATV_OPT_v (1<<2)
> - typedef char BUG_const_mismatch[
> - CATV_OPT_e == VISIBLE_ENDLINE && CATV_OPT_t == VISIBLE_SHOW_TABS
> - ? 1 : -1
> - ];
This check is useful. I would like to retain it. How about moving it
to global scope?
#define CATV_OPT_e (1<<0)
#define CATV_OPT_t (1<<1)
#define CATV_OPT_v (1<<2)
struct BUG_const_mismatch {
char BUG_const_mismatch[
CATV_OPT_e == VISIBLE_ENDLINE && CATV_OPT_t == VISIBLE_SHOW_TABS
? 1 : -1
];
};
int catv_main(...)...
_______________________________________________
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic