From 34a8f51eb82458c52fb8d3510175c08c891867b5 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Tue, 21 Jan 2025 13:47:27 +0100 Subject: [PATCH] LibGC: Add ability to construct RootVector from a span of T --- Libraries/LibGC/RootVector.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Libraries/LibGC/RootVector.h b/Libraries/LibGC/RootVector.h index 5e05bf4fd68..9c7b7b3cf36 100644 --- a/Libraries/LibGC/RootVector.h +++ b/Libraries/LibGC/RootVector.h @@ -46,6 +46,12 @@ public: virtual ~RootVector() = default; + RootVector(Heap& heap, ReadonlySpan other) + : RootVectorBase(heap) + , Vector(other) + { + } + RootVector(RootVector const& other) : RootVectorBase(*other.m_heap) , Vector(other)