
11 Feb
2007
11 Feb
'07
11:54 p.m.
On Sunday 11 February 2007 06:36 pm, Frank Mori Hess wrote:
Sorry, I only looked at your group_key_less comparison here. I saw now that you use a list as container and a linear search in signalN::connect, which ensures the correct order. That works as expected, of course, but significantly changes the complexity of connect() to the worse compared to what the current docs say.
connect() is O(n) anyways, if you do automatic slot cleanup there.
I suppose a binary search would work too, since the list is kept ordered. That would reduce the insertion time when a group is specified to O(log n). Connect for ungrouped slots is already O(1). -- Frank