From 221bd464a0adcca7e0ffb304f3603e7333202b0b Mon Sep 17 00:00:00 2001 From: Daniel Bertalan Date: Sun, 20 Jun 2021 19:57:37 +0200 Subject: [PATCH] Kernel: Fix attribute ordering Clang requires that attributes declared using the bracketed `[[attr_name]]` syntax come before those with `__attribute__((attr-name))`. This fixes a Clang build error. --- Kernel/init.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Kernel/init.cpp b/Kernel/init.cpp index 50133c5c0b..5b423e3a94 100644 --- a/Kernel/init.cpp +++ b/Kernel/init.cpp @@ -103,7 +103,7 @@ static Processor s_bsp_processor; // global but let's keep it "private" // Once multi-tasking is ready, we spawn a new thread that starts in the // init_stage2() function. Initialization continues there. -extern "C" UNMAP_AFTER_INIT [[noreturn]] void init() +extern "C" [[noreturn]] UNMAP_AFTER_INIT void init() { if ((FlatPtr)&end_of_kernel_image >= 0xc2000000u) { // The kernel has grown too large again! @@ -193,7 +193,7 @@ extern "C" UNMAP_AFTER_INIT [[noreturn]] void init() // // The purpose of init_ap() is to initialize APs for multi-tasking. // -extern "C" UNMAP_AFTER_INIT [[noreturn]] void init_ap(u32 cpu, Processor* processor_info) +extern "C" [[noreturn]] UNMAP_AFTER_INIT void init_ap(u32 cpu, Processor* processor_info) { processor_info->early_initialize(cpu);