From d001f8ba702b930a6e8fc2e8bcc7553f57bf92ff Mon Sep 17 00:00:00 2001 From: Hendiadyoin1 Date: Wed, 22 Dec 2021 16:34:22 +0100 Subject: [PATCH] LibX86: Mark two InstructionDescriptor functions as const Thanks clang-tidy --- Userland/Libraries/LibX86/Instruction.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Userland/Libraries/LibX86/Instruction.h b/Userland/Libraries/LibX86/Instruction.h index fd550400e7..1fe247e486 100644 --- a/Userland/Libraries/LibX86/Instruction.h +++ b/Userland/Libraries/LibX86/Instruction.h @@ -205,14 +205,14 @@ struct InstructionDescriptor { // a non-null slashes member that's indexed by the three R/M bits. InstructionDescriptor* slashes { nullptr }; - unsigned imm1_bytes_for_address_size(bool a32) + unsigned imm1_bytes_for_address_size(bool a32) const { if (imm1_bytes == CurrentAddressSize) return a32 ? 4 : 2; return imm1_bytes; } - unsigned imm2_bytes_for_address_size(bool a32) + unsigned imm2_bytes_for_address_size(bool a32) const { if (imm2_bytes == CurrentAddressSize) return a32 ? 4 : 2;