forked from Alepha/Alepha
Create thread context for the main thread.
We probably should also do it for any random thread... but this mostly would be to prevent crashes... as there's no Alepha thread object associated with the
This commit is contained in:
@ -90,6 +90,11 @@ namespace Alepha::Hydrogen::detail::Thread_m
|
|||||||
state()->interruption_point();
|
state()->interruption_point();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static auto init= Utility::enroll <=[]
|
||||||
|
{
|
||||||
|
state()= std::make_shared< ThreadState >();
|
||||||
|
};
|
||||||
|
|
||||||
struct Thread::Impl
|
struct Thread::Impl
|
||||||
{
|
{
|
||||||
std::thread thr;
|
std::thread thr;
|
||||||
|
|||||||
Reference in New Issue
Block a user