Index | Thread | Search

From:
Todd C. Miller <millert@openbsd.org>
Subject:
Re: bgpd vs bison: rename some enums
To:
Claudio Jeker <cjeker@diehard.n-r-g.com>
Cc:
tech@openbsd.org
Date:
Mon, 16 Dec 2024 08:49:12 -0700

Download raw body.

Thread
On Mon, 16 Dec 2024 16:40:25 +0100, Claudio Jeker wrote:

> Bison uses an enum for the yacc tokens and so we end up with the
> redefinition of NOTIFICATION.
>
> parse.c:390:5: warning: declaration shadows a variable in the global scope
> [-Wshadow]
>   390 |     NOTIFICATION = 318,            /* NOTIFICATION  */
>       |     ^
> ./session.h:75:2: note: previous declaration is here
>    75 |         NOTIFICATION,
>       |         ^
>
> Now it is easier to prefix the msg_type enums in session.h so the below
> diff does that. With that make YACC=bison works.

That seems like the best approach.  OK millert@

 - todd