mirror of
https://github.com/wheremyfoodat/Panda3DS.git
synced 2025-06-06 02:51:38 +12:00
Use std::span
for CPU register-state
Following the trend of #33: `std::span` provides some useful utility functions like `size_bytes()` and `as_bytes()` and serves as a better non-owning "chunk of data"-type over just passing around an `std::array&`.
This commit is contained in:
parent
c6f5d19983
commit
fde93381a5
5 changed files with 38 additions and 32 deletions
|
@ -2,10 +2,12 @@
|
|||
#include <array>
|
||||
#include <cassert>
|
||||
#include <limits>
|
||||
#include <span>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include "kernel_types.hpp"
|
||||
|
||||
#include "helpers.hpp"
|
||||
#include "kernel_types.hpp"
|
||||
#include "logger.hpp"
|
||||
#include "memory.hpp"
|
||||
#include "resource_limits.hpp"
|
||||
|
@ -14,7 +16,7 @@
|
|||
class CPU;
|
||||
|
||||
class Kernel {
|
||||
std::array<u32, 16>& regs;
|
||||
std::span<u32, 16> regs;
|
||||
CPU& cpu;
|
||||
Memory& mem;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue