Re: [PATCH 1/3] Warn on unknown attributes instead of throwing errors

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 02/11/16 21:59, Luc Van Oostenryck wrote:
> GCC creates new attributes quite often, generaly for specific
> usages irrelevant to what sparse is used for.
> Throwing errors on these create needless noise and annoyance
> which is better to avoid.
> 
> 
> Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@xxxxxxxxx>
> ---
>  parse.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/parse.c b/parse.c
> index 205e1264..212fae3a 100644
> --- a/parse.c
> +++ b/parse.c
> @@ -1230,7 +1230,8 @@ static struct token *recover_unknown_attribute(struct token *token)
>  {
>  	struct expression *expr = NULL;
>  
> -	sparse_error(token->pos, "attribute '%s': unknown attribute", show_ident(token->ident));
> +	if (Wunknown_attribute)

Since Wunknown_attribute is not declared yet, this won't even compile.
Simply squash this into patch #2.

Apart from that, looks good.

Thanks!

ATB,
Ramsay Jones
--
To unsubscribe from this list: send the line "unsubscribe linux-sparse" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Newbies FAQ]     [LKML]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Trinity Fuzzer Tool]

  Powered by Linux