mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
Added support for thread cancellation on Linux
This commit is contained in:
@@ -23,6 +23,7 @@ struct StlThreadEnvironment {
|
||||
public:
|
||||
EnvThread(std::function<void()> f) : thr_(std::move(f)) {}
|
||||
~EnvThread() { thr_.join(); }
|
||||
void Cancel() { EIGEN_THREAD_CANCEL(thr_); }
|
||||
|
||||
private:
|
||||
std::thread thr_;
|
||||
|
||||
Reference in New Issue
Block a user