Coverage Report

Created: 2025-07-12 06:42

/src/immer/extra/fuzzer/fuzzer_gc_guard.hpp
Line
Count
Source
1
//
2
// immer: immutable data structures for C++
3
// Copyright (C) 2016, 2017, 2018 Juan Pedro Bolivar Puente
4
//
5
// This software is distributed under the Boost Software License, Version 1.0.
6
// See accompanying file LICENSE or copy at http://boost.org/LICENSE_1_0.txt
7
//
8
9
#pragma once
10
11
#include <immer/heap/gc_heap.hpp>
12
13
struct fuzzer_gc_guard
14
{
15
17.4k
    fuzzer_gc_guard() { GC_disable(); }
16
17
    ~fuzzer_gc_guard()
18
17.4k
    {
19
17.4k
        GC_enable();
20
17.4k
        GC_gcollect();
21
17.4k
    }
22
};