LibX86: Use MakeUnsigned<T> from AK instead of making a custom one

This commit is contained in:
Andreas Kling 2020-04-15 16:52:43 +02:00
parent bdc753ebd2
commit 3cdf4cd204
Notes: sideshowbarker 2024-07-19 07:34:26 +09:00

View File

@ -26,6 +26,7 @@
#pragma once
#include <AK/StdLibExtras.h>
#include <AK/String.h>
#include <AK/Types.h>
@ -39,27 +40,6 @@ public:
virtual String symbolicate(FlatPtr, u32* offset = nullptr) const = 0;
};
template<typename T>
struct MakeUnsigned {
typedef T type;
};
template<>
struct MakeUnsigned<i8> {
typedef u8 type;
};
template<>
struct MakeUnsigned<i16> {
typedef u32 type;
};
template<>
struct MakeUnsigned<i32> {
typedef u32 type;
};
template<>
struct MakeUnsigned<i64> {
typedef u64 type;
};
template<typename T>
struct TypeTrivia {
static const size_t bits = sizeof(T) * 8;