[vlc-devel] [PATCH] input/mrl_helpers: fix warning related to iteration variable

Rémi Denis-Courmont remi at remlab.net
Tue Feb 21 10:07:47 CET 2017


On February 20, 2017 7:14:04 PM GMT+02:00, "Filip Roséen" <filip at atch.se> wrote:
>Hi Rémi,
>
>On 2017-02-20 18:32, Rémi Denis-Courmont wrote:
>
>> Le maanantaina 20. helmikuuta 2017, 14.53.50 EET Filip Roséen a écrit
>:
>> > Following the changes in 7ecd927 the changed line caused a warning
>> > related to signed vs unsigned integer comparision; this simply
>silence
>> > that warning by using the now relevant type.
>> 
>> Well yes but I left it because this code should use init/clear
>instead of new/
>> destroy (and I have not yet fixed that occurrence).
>
>Understood, I just wanted to get rid of the current warnings as they
>hurt my eyes. Unless you plan on fixing the migration from
>`vlc_array_new` to `vlc_array_init` and `vlc_array_clear` tonight I'd
>be happy to do it.
>
>While we are speaking about the matter, do you think it would make
>sense to introduce a *`vlc_array_t`-initializer* that could be used as
>the below (not sure about the name though).
>
>    vlc_array_t foo = VLC_ARRAY_INIT;
>
>instead of having:
>
>    vlc_array_t foo;
>    vlc_array_init( &foo );
>
>Best Regards,\
>Filip Roséen

Help yourself then.

I have no opinion on the initializer. It is only "necessary" for global or static scenarii, which I think we do not have. (And even then, the default initialization would actually work, if not pretty.)
-- 
Rémi Denis-Courmont
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20170221/f2102875/attachment.html>


More information about the vlc-devel mailing list