[alsa-lib][PATCH 0/6] add API of equality and comparison for a pair of control element IDs
Takashi Sakamoto
o-takashi at sakamocchi.jp
Thu Mar 18 17:56:34 CET 2021
On Fri, Mar 19, 2021 at 01:37:15AM +0900, Takashi Sakamoto wrote:
> As I described, your old implementation is not acceptable just by renaming.
> Although the idea of inline definitions is itself preferable. I suspect whether
> inline definition for your comparison algorithm is really less overhead than
> function call.
>
> Anyway I'll post revised version of patchset later.
Oops. These APIs have arguments with opaque pointers. In the case,
inline definition is not available since the layout of structure underlying
the pointer is not available for userspace applications. Thus the rest of
issue is whether to use 'tuple' or 'fields' in the name of new API.
In my opinion, 'fields' is generic expression and could give impression to
application developers that it includes numid field as well. On the other
hand, 'tuple' is weak expression somehow and the developers easily find
its meaning in alsa-lib documentation (see line 80). When considering about
helpfulness to developers, 'tuple' seems to be better than 'fields'.
Thanks
Takashi Sakamoto
More information about the Alsa-devel
mailing list