mirror of
https://github.com/RGBCube/serenity
synced 2025-06-01 06:28:13 +00:00
UserspaceEmulator+LibX86: Clean up some obnoxious template spam
Don't require clients to templatize modrm().read{8,16,32,64}() with the ValueWithShadow type when we can figure it out automatically. The main complication here is that ValueWithShadow is a UE concept while the MemoryOrRegisterReference inlines exist at the lower LibX86 layer and so doesn't have direct access to those types. But that's nothing we can't solve with some simple template trickery. :^)
This commit is contained in:
parent
993ceb66fd
commit
60c2fba9b9
3 changed files with 110 additions and 105 deletions
|
@ -53,6 +53,11 @@ class SoftCPU final
|
|||
: public X86::Interpreter
|
||||
, public X86::InstructionStream {
|
||||
public:
|
||||
using ValueWithShadowType8 = ValueWithShadow<u8>;
|
||||
using ValueWithShadowType16 = ValueWithShadow<u16>;
|
||||
using ValueWithShadowType32 = ValueWithShadow<u32>;
|
||||
using ValueWithShadowType64 = ValueWithShadow<u64>;
|
||||
|
||||
explicit SoftCPU(Emulator&);
|
||||
void dump() const;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue