Re: [PATCH v2 1/7] banned-die: create header for banning of functions
- From
Elijah Newren <newren@gmail.com>
- Date
- Aug 25, 2026, 22:14 UTC
- Message-ID
- <CABPp-BHtmjSqkgL+RL=nmd1VNqqZ6vDUhQxj0AnEzAHZxznoHw@mail.gmail.com>
- In-Reply-To
- <84634717e2eca479026d1cdf39a089a8f61d131e.1787684181.git.gitgitgadget@gmail.com>
On Tue, Aug 25, 2026 at 11:58 AM Derrick Stolee via GitGitGadget <gitgitgadget@gmail.com> wrote:
>
[...]
> +#undef die > +#define die banned(die)
Shouldn't that be BANNED(die) to match all the other cases in the code (and avoid an obtuse "implicit declaration of function 'banned'" instead of the nicer "sorry_die_is_a_banned_function" message)?
Show 12 quoted lines
> + > +#endif /* BANNED_DIE_H */ > diff --git a/trace2.c b/trace2.c > index c23c0a227b..1d0ed2db2b 100644 > --- a/trace2.c > +++ b/trace2.c > @@ -17,6 +17,7 @@ > #include "trace2/tr2_tgt.h" > #include "trace2/tr2_tls.h" > #include "trace2/tr2_tmr.h" > +#include "banned-die.h" >
Is there a risk that future folks add new includes at the end of the list, then functions in them get added to banned-die.h, but are silently ignored because banned-die.h wasn't the last include?