Reorganize the list handling of the pthreads objects by using the List
template class and remove a lot of duplicate code.
2002-02-28 Thomas Pfaff <[EMAIL PROTECTED]>
* thread.h (class List): Move inline code inside of class
declaration.
(pthread_mutex::fixup_after_fork
On Fri, 2003-02-28 at 22:10, Thomas Pfaff wrote:
> Reorganize the list handling of the pthreads objects by using the List
> template class and remove a lot of duplicate code.
This looks good, except for for_each. can you do a proper for_each
template implementation?
Rob
--
GPG key available at:
I think that the code could be simplified by making callback a pointer to
member function.
void forEach (void (ListNode::*callback) ())
{
ListNode *aNode = head;
while (aNode)
{
(aNode->*callback) ();
aNode = aNode->next;
}
}
With this change you do not need a static to m
On Wed, 2003-03-19 at 21:56, Thomas Pfaff wrote:
> I think that the code could be simplified by making callback a pointer to
> member function.
>
> void forEach (void (ListNode::*callback) ())
> {
> ListNode *aNode = head;
> while (aNode)
> {
> (aNode->*callback) ();
> aNode =