[vlc-devel] [PATCH 5/5] variables: warn when a variable is created twice in the same object

Rémi Denis-Courmont remi at remlab.net
Fri Mar 13 16:39:24 CET 2020

Le perjantaina 13. maaliskuuta 2020, 16.00.32 EET Steve Lhomme a écrit :
> Only in debug builds.

At this time, variables are reference counted. There is still code that 
depends on this. I'm not saying that it's a good thing - I would not have 
designed it like that personally.

But it is what it is, and until somebody goes through the pain-staking work of 
reviewing the whole code base for potentially multiply referenced variables, 
then we have to keep it that way.

We don't start warning until we have made a honest effort at not triggering the 
warning. Preferably, we don't warn at all and we instead redesign the API so 
that you can't get it wrong, or it'll fail at build time.

Rémi Denis-Courmont

More information about the vlc-devel mailing list