Resolve some TODOs

This commit is contained in:
2024-02-08 21:29:18 -05:00
parent e5f8a18acb
commit 97b3de834f
4 changed files with 9 additions and 13 deletions

View File

@@ -1,6 +1,7 @@
#pragma once
#include "../../Auxiliary/bits.hpp"
#include "../../Auxiliary/type_traits.hpp"
#include "../../System/IOPorts/gpu_io.hpp"
namespace JabyEngine {
namespace GPU {
@@ -38,14 +39,14 @@ namespace JabyEngine {
}
template<typename T>
enable_if<!is_pointer<T>::value, T&>::type concat(T& obj) {
enable_if<!is_pointer<T>::value, Link&>::type concat(T& obj) {
Link::set_adr(&obj);
return obj;
return *this;
}
template<typename T>
enable_if<!is_pointer<T>::value, const T&>::type concat(const T& obj) {
return concat(const_cast<T&>(obj));
enable_if<!is_pointer<T>::value, const Link&>::type concat(const T& obj) {
return concat(const_cast<Link&>(obj));
}
constexpr void terminate() {
@@ -77,8 +78,7 @@ namespace JabyEngine {
return &this->element;
}
// TODO: Replace this magic number?
static_assert((sizeof(T) >> 2) <= 16);
static_assert((sizeof(T) >> 2) <= GPU_IO::FIFOWordSize);
};
namespace internal {