ladybird/Libraries/LibGC/HeapRoot.h

38 lines
717 B
C
Raw Permalink Normal View History

/*
* Copyright (c) 2023-2025, Aliaksandr Kalenik <kalenik.aliaksandr@gmail.com>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#pragma once
#include <AK/Optional.h>
#include <AK/SourceLocation.h>
#include <LibGC/Export.h>
namespace GC {
2025-06-28 05:34:31 -03:00
struct GC_API HeapRoot {
enum class Type {
2026-04-09 12:33:01 -03:00
ConservativeHashMap,
2026-04-09 10:59:02 -03:00
ConservativeHashTable,
ConservativeVector,
CrossHeapMember,
HeapFunctionCapturedPointer,
MustSurviveGC,
RegisterPointer,
Root,
RootHashMap,
2026-04-09 10:33:59 -03:00
RootHashTable,
RootVector,
StackPointer,
VM,
};
Type type;
SourceLocation const* location { nullptr };
Optional<u32> stack_frame_index {};
};
}