Re: gtkmm 3.0: Removing ListHandle, SListHandle, etc




Murray Cumming a écrit :

In gtkmm 3.0, I'd like to remove the intermediate container types
because they just confuse people and make it necessary to read the
documentation.

Guillaume Brocker wrote:

I solved a similar question by making the return type of such methods template. The effective container type choice is left to the caller, so he can use what's most useful for him. You don't have to rewrite the code for each container type you want to support. The only prerequisite was the container type have to be a model of back insertion sequence so I was able to write generic code for inserting items in the collections.

I suspect this too would confuse the novice programmer. In any case it would need an explanation in the docs, as does the existing solution.

Mark


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]