From 3dac1f8ac5d765e5076c50d63a5e3d0c8509973e Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Tue, 16 Jul 2019 13:44:41 +0200 Subject: [PATCH] Kernel: Remove use of [[gnu::pure]]. I was messing around with this to tell the compiler that these functions always return the same value no matter how many times you call them. It doesn't really seem to improve code generation and it looks weird so let's just get rid of it. --- Kernel/Devices/KeyboardDevice.h | 2 +- Kernel/FileSystem/DevPtsFS.h | 2 +- Kernel/FileSystem/ProcFS.h | 2 +- Kernel/FileSystem/VirtualFileSystem.h | 2 +- Kernel/VM/MemoryManager.h | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/Kernel/Devices/KeyboardDevice.h b/Kernel/Devices/KeyboardDevice.h index 37472daf4d4..8a90694d941 100644 --- a/Kernel/Devices/KeyboardDevice.h +++ b/Kernel/Devices/KeyboardDevice.h @@ -15,7 +15,7 @@ class KeyboardDevice final : public IRQHandler public: using Event = KeyEvent; - [[gnu::pure]] static KeyboardDevice& the(); + static KeyboardDevice& the(); virtual ~KeyboardDevice() override; KeyboardDevice(); diff --git a/Kernel/FileSystem/DevPtsFS.h b/Kernel/FileSystem/DevPtsFS.h index b285814cf5a..c834b82156b 100644 --- a/Kernel/FileSystem/DevPtsFS.h +++ b/Kernel/FileSystem/DevPtsFS.h @@ -8,7 +8,7 @@ class SlavePTY; class DevPtsFS final : public SynthFS { public: - [[gnu::pure]] static DevPtsFS& the(); + static DevPtsFS& the(); virtual ~DevPtsFS() override; static NonnullRefPtr create(); diff --git a/Kernel/FileSystem/ProcFS.h b/Kernel/FileSystem/ProcFS.h index 1adf44705cd..14019b4fd5b 100644 --- a/Kernel/FileSystem/ProcFS.h +++ b/Kernel/FileSystem/ProcFS.h @@ -13,7 +13,7 @@ class ProcFS final : public FS { friend class ProcFSInode; public: - [[gnu::pure]] static ProcFS& the(); + static ProcFS& the(); virtual ~ProcFS() override; static NonnullRefPtr create(); diff --git a/Kernel/FileSystem/VirtualFileSystem.h b/Kernel/FileSystem/VirtualFileSystem.h index adf82d0b661..230dadb7ad6 100644 --- a/Kernel/FileSystem/VirtualFileSystem.h +++ b/Kernel/FileSystem/VirtualFileSystem.h @@ -51,7 +51,7 @@ public: RefPtr m_host_custody; }; - [[gnu::pure]] static VFS& the(); + static VFS& the(); VFS(); ~VFS(); diff --git a/Kernel/VM/MemoryManager.h b/Kernel/VM/MemoryManager.h index b3d59338d61..002911baaeb 100644 --- a/Kernel/VM/MemoryManager.h +++ b/Kernel/VM/MemoryManager.h @@ -40,7 +40,7 @@ class MemoryManager { friend ByteBuffer procfs$memstat(InodeIdentifier); public: - [[gnu::pure]] static MemoryManager& the(); + static MemoryManager& the(); static void initialize();