This is the mail archive of the
elfutils-devel@sourceware.org
mailing list for the elfutils project.
Re: [patch 1/2] Rename COMPAT_VERSION to COMPAT_VERSION_SAMEPROTO
- From: Mark Wielaard <mjw at redhat dot com>
- To: elfutils-devel at lists dot fedorahosted dot org
- Date: Wed, 01 May 2013 10:34:57 +0200
- Subject: Re: [patch 1/2] Rename COMPAT_VERSION to COMPAT_VERSION_SAMEPROTO
On Tue, Apr 30, 2013 at 02:37:46PM +0200, Jan Kratochvil wrote:
> jankratochvil/compatversion
>
> [...]
> > If I read this right then for the new COMPAT_VERSION macro we don't define
> > a _compat_prefix_name symbol anymore.
>
> A bug, thanks.
Aha, OK, now it makes more sense. One last question:
> +# define COMPAT_VERSION_NEWPROTO(name, version, prefix) \
> + asm (".symver _compat." #version "." #name "," #name "@" #version); \
> + __typeof (_compat_##prefix##_##name) _compat_##prefix##_##name \
> + asm ("_compat." #version "." #name);
> # define COMPAT_VERSION(name, version, prefix) \
> asm (".symver _compat." #version "." #name "," #name "@" #version); \
> __typeof (name) _compat_##prefix##_##name asm ("_compat." #version "." #name);
Wouldn't the new definition just work always? Whether the prototype is
different or the same? That would simplify things even more by just using
the new definition as COMPAT_VERSION. But I might be missing something
(I still don't fully understand that last asm bit).
Thanks,
Mark