[vlc-devel] commit: Added picture_pool_NewExtended. (Laurent Aimar )

Pierre d'Herbemont pdherbemont at gmail.com
Tue Sep 8 13:53:43 CEST 2009


On Sep 8, 2009, at 8:29 AM, Rémi Denis-Courmont wrote:

>
>
>
> On Tue, 8 Sep 2009 02:26:04 +0200, Pierre d'Herbemont
> <pdherbemont at gmail.com> wrote:
>>
>>
>> On Sep 7, 2009, at 11:05 PM, "Rémi Denis-Courmont" <remi at remlab.net>
>> wrote:
>>
>>> Le lundi 7 septembre 2009 23:57:52 Pierre d'Herbemont, vous avez écr
>>> it :
>>>> In this case NewWithConfiguration seems more appropriate. And
>>>> "configuration" should  probably be "callback".
>>>
>>> Do you really need to invent the longest possible names all the  
>>> time?
>>
>> You are just saying, that short is good. And I do agree.
>>
>> However someone new to the code will appreciate meaningful and clear
>> name.   I am always open to better suggestion.
>
> WithConfiguration reads just as stupid as Extended. In either case, it
> won't scale to further adding parameters.

cf below.

>> Also, if you want to put it that way, Extended is a waste of 8 chars.
>
> Yes. We might as well have a single function and give a NULL  
> parameter to
> get the non-extended behavior.

Agreed.

>> I am concerned about this "lazy" way to extend existing API. And it
>> shouldn't be considered as a good practice, even if it's a common  
>> one.
>> Will you end up with an ExtendedExtended if you want a more
>> specialized call?
>
> And WithConfigurationAndSettings is supposed to be better?

Yes for the "With...And...", no for "Configuration" and "Settings"  
which are of course too vague to be meaningful.

The "Configuration" name was badly chosen to match the parameter and  
the structure name. I think that "Callback" would probably be nicer  
for that parameter name and structure name. This could be discussed as  
well.

Pierre.


More information about the vlc-devel mailing list