summaryrefslogtreecommitdiff
path: root/inc/cache.h
diff options
context:
space:
mode:
authorbd <bdunahu@operationnull.com>2025-03-10 16:44:39 -0400
committerbd <bdunahu@operationnull.com>2025-03-10 16:44:39 -0400
commit141494cb961b72a7ad56c3e754af43a07f1b8c23 (patch)
treebfd4d2a5303d15f625b4d945800c0c7c55a2bac7 /inc/cache.h
parent486d18df5ca93e043fdd14fac1d22b5fe40fb6f6 (diff)
Add starter overloaded << operator for cache
Diffstat (limited to 'inc/cache.h')
-rw-r--r--inc/cache.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/inc/cache.h b/inc/cache.h
index b7b72cf..0c9b3d7 100644
--- a/inc/cache.h
+++ b/inc/cache.h
@@ -3,6 +3,7 @@
#include "definitions.h"
#include "storage.h"
#include <array>
+#include <ostream>
class Cache : public Storage
{
@@ -30,7 +31,7 @@ class Cache : public Storage
* TODO this doesn't seem like good object-oriented practice.
* @return this->meta
*/
- std::array<std::array<int, 2>, L1_CACHE_SIZE> *get_meta();
+ std::array<std::array<int, 2>, L1_CACHE_SIZE> get_meta() const;
private:
/**
@@ -49,4 +50,6 @@ class Cache : public Storage
std::array<std::array<int, 2>, L1_CACHE_SIZE> meta;
};
+std::ostream &operator<<(std::ostream &os, const Cache &a);
+
#endif /* CACHE_H_INCLUDED */