diff options
author | Yorick van Pelt <yorick@yorickvanpelt.nl> | 2023-02-03 17:50:01 +0100 |
---|---|---|
committer | Yorick van Pelt <yorick@yorickvanpelt.nl> | 2023-03-01 13:55:41 +0100 |
commit | eaeb994d8b9d2152e076897bf430c8ac205d3d1a (patch) | |
tree | 48394e491b460ef1946c1d4075c46bbf77300cf8 /src/libutil/serialise.hh | |
parent | 0fd8f542a8ddb303f589ff6ca3343f36e3a783c0 (diff) |
Disable GC inside coroutines on mac OS
Diffstat (limited to 'src/libutil/serialise.hh')
-rw-r--r-- | src/libutil/serialise.hh | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/libutil/serialise.hh b/src/libutil/serialise.hh index 7da5b07fd..fb1f14a3b 100644 --- a/src/libutil/serialise.hh +++ b/src/libutil/serialise.hh @@ -501,4 +501,14 @@ struct StackAllocator { static StackAllocator *defaultAllocator; }; +/* Disabling GC when entering a coroutine (on macos). + ::create is to avoid boehm gc dependency in libutil. + */ +class DisableGC { +public: + DisableGC() {}; + virtual ~DisableGC() {}; + static std::shared_ptr<DisableGC> (*create)(); +}; + } |