On Sat, 21 Apr 2012 00:48:32 +0200 Cedric BAIL <[email protected]> said:

> On Fri, Apr 20, 2012 at 5:06 PM, Gustavo Sverzut Barbieri
> <[email protected]> wrote:
> > On Fri, Apr 20, 2012 at 5:31 AM, Enlightenment SVN
> > <[email protected]> wrote:
> >> Log:
> >> eina: fix Eina_Inarray API to at least match Eina_Array API.
> >>
> >>  NOTE: some of this function should be moved as inline, but that's to late
> >> for a change I think. So we will fix that if needed.
> >>
> >>  Second point, I am not happy with is eina_inarray_insert and
> >> eina_inarray_insert_at. The naming is really poor.
> >
> > I really disagree here. insert_at() is very clear what it's doing.
> > Same for append() and prepend(). However push() is something unclear
> > to unused people as it may be pushed at head or at tail.
> 
> > Also, push() is not present in lists, for instance.
> 
> The think is that inarray is an ... array. So it should have the same
> API as Eina_Array. As an array, it should really be used like a stack
> not like a list or you will use a very inneficient path. That's why it
> should also not expose an API like it was a list of people will start
> missusing it in my opinion.

i agree here totally. if it has the same api as eina_array (in function) then
it should have the same name. regardless if it is a good name or not.
consistency. i looked at the insert func and went "wtf? why a compare func?
why not an index?" my first reaction was bewilderment.

-- 
------------- Codito, ergo sum - "I code, therefore I am" --------------
The Rasterman (Carsten Haitzler)    [email protected]


------------------------------------------------------------------------------
For Developers, A Lot Can Happen In A Second.
Boundary is the first to Know...and Tell You.
Monitor Your Applications in Ultra-Fine Resolution. Try it FREE!
http://p.sf.net/sfu/Boundary-d2dvs2
_______________________________________________
enlightenment-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel

Reply via email to