From 8558f80b4077536d6aa46b97328d6df1210e261f Mon Sep 17 00:00:00 2001 From: Richard-Qin-X Date: Thu, 13 Aug 2026 13:18:05 +0800 Subject: [Support] Centralize error context handling --- backend/lib/CodeGen/RegAllocInternal.h | 9 --------- 1 file changed, 9 deletions(-) (limited to 'backend/lib/CodeGen/RegAllocInternal.h') diff --git a/backend/lib/CodeGen/RegAllocInternal.h b/backend/lib/CodeGen/RegAllocInternal.h index 0becb92..52840cf 100644 --- a/backend/lib/CodeGen/RegAllocInternal.h +++ b/backend/lib/CodeGen/RegAllocInternal.h @@ -26,9 +26,6 @@ #include #include #include -#include -#include -#include #include namespace rcc::regalloc_detail { @@ -39,12 +36,6 @@ struct AllocationRunResult final { bool ChangedFrame = false; }; -[[nodiscard]] inline Error withPrefix(const Error &Failure, std::string_view Prefix) { - std::string Message(Prefix); - Message.append(Failure.message()); - return Error(Failure.code(), std::move(Message)); -} - [[nodiscard]] inline Expected virtualRegisterAt(std::size_t Index) { auto Reg = Register::makeVirtual(Index); if (!Reg) -- cgit v1.2.3