Exemplo n.º 1
0
    /**
     * Destructor
     * Effects: Call the CallableThread functor before destroying the owned thread.
     * Remark: The CallableThread should not throw when joining the thread as the scoped variable is on a scope outside the thread function.
     */
    ~strict_scoped_thread()
    {
      CallableThread on_destructor;

      on_destructor(t_);
    }
Exemplo n.º 2
0
    ~thread_guard()
    {
      CallableThread on_destructor;

      on_destructor(t_);
    }