Limit concat to non pointer types to avoid hard to track problems
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
#pragma once
|
||||
#include "../../Auxiliary/bits.hpp"
|
||||
#include "../../Auxiliary/type_traits.hpp"
|
||||
|
||||
namespace JabyEngine {
|
||||
namespace GPU {
|
||||
@@ -37,13 +38,13 @@ namespace JabyEngine {
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
T& concat(T& obj) {
|
||||
enable_if<!is_pointer<T>::value, T&>::type concat(T& obj) {
|
||||
Link::set_adr(&obj);
|
||||
return obj;
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
const T& concat(const T& obj) {
|
||||
enable_if<!is_pointer<T>::value, const T&>::type concat(const T& obj) {
|
||||
return concat(const_cast<T&>(obj));
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user