diff options
author | Yorick van Pelt <yorick@yorickvanpelt.nl> | 2023-02-03 17:50:01 +0100 |
---|---|---|
committer | Théophane Hufschmitt <theophane.hufschmitt@tweag.io> | 2023-04-07 14:52:59 +0200 |
commit | 2c53ef1bfee7c7afea889f42b9ef13e1007ad228 (patch) | |
tree | 8aba03476e03d2d7631f596d0cb2ab45ee9bd7f3 /src/libutil/serialise.hh | |
parent | 81dfc2b01231c65137017de092c8506838fadd94 (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 2cf527023..612196fd2 100644 --- a/src/libutil/serialise.hh +++ b/src/libutil/serialise.hh @@ -551,4 +551,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)(); +}; + } |