Re: [PATCH 1/4] trace2: fix signature of trace2_def_param() macro
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Nov 23, 2023, 06:10 UTC
- Message-ID
- <xmqqil5tatl3.fsf@gitster.g>
- In-Reply-To
- <97d17c22ff310c26c3ec391c7bf870e7e5bab4f8.1700680717.git.gitgitgadget@gmail.com>
"Jeff Hostetler via GitGitGadget" <gitgitgadget@gmail.com> writes:
Show 25 quoted lines
> From: Jeff Hostetler <jeffhostetler@github.com> > > Add `struct key_value_info` argument to `trace2_def_param()`. > > In dc90208497 (trace2: plumb config kvi, 2023-06-28) a `kvi` > argument was added to `trace2_def_param_fl()` but the macro > was not up updated. Let's fix that. > > Signed-off-by: Jeff Hostetler <jeffhostetler@github.com> > --- > trace2.h | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/trace2.h b/trace2.h > index 40d8c2e02a5..1f0669bbd2d 100644 > --- a/trace2.h > +++ b/trace2.h > @@ -337,8 +337,8 @@ struct key_value_info; > void trace2_def_param_fl(const char *file, int line, const char *param, > const char *value, const struct key_value_info *kvi); > > -#define trace2_def_param(param, value) \ > - trace2_def_param_fl(__FILE__, __LINE__, (param), (value)) > +#define trace2_def_param(param, value, kvi) \ > + trace2_def_param_fl(__FILE__, __LINE__, (param), (value), (kvi))
IOW, this macro was not used back when it was updated, and nobody used it since then?
I briefly wondered if we are better off removing it but that does not make sense because you are adding a new (and only) user to it.
Will queue. Thanks.
> > /* > * Tell trace2 about a newly instantiated repo object and assign