[vlc-devel] [VLC 3.x 2/2] codec: dav1d: do not use VLC_CLIP

Alexandre Janniaux ajanni at videolabs.io
Wed Apr 7 08:07:08 UTC 2021


On Wed, Apr 07, 2021 at 07:29:21AM +0200, Steve Lhomme wrote:
> On 2021-04-06 16:25, Rémi Denis-Courmont wrote:
> > Le tiistaina 6. huhtikuuta 2021, 17.07.01 EEST Steve Lhomme a écrit :
> > > Why ?
> >
> > Because it's a poor excuse of a functional macro that is not expansion-safe,
> > and whose behaviour is utterly trivial.
> I disagree. This is the perfect use case for it. And replacing a one liner
> by 3 lines is never good in my book.

I too prefer VLC_CLIP, but it's non-obvious that it has been
misused here, whereas it is with condition so the change from
Marvin makes sense.

Maybe we can switch to using a _Generic/template<> inline
vlc_clip instead too?

Alexandre Janniaux

More information about the vlc-devel mailing list