Remove unnecessary constexpr. (#7466)
This commit is contained in:
parent
0c67685e43
commit
5262e933f7
@ -468,7 +468,7 @@ class ArrayInterface {
|
||||
XGBOOST_DEVICE size_t Stride(size_t i) const { return strides[i]; }
|
||||
|
||||
template <typename Fn>
|
||||
XGBOOST_HOST_DEV_INLINE constexpr decltype(auto) DispatchCall(Fn func) const {
|
||||
XGBOOST_HOST_DEV_INLINE decltype(auto) DispatchCall(Fn func) const {
|
||||
using T = ArrayInterfaceHandler::Type;
|
||||
switch (type) {
|
||||
case T::kF4:
|
||||
@ -506,7 +506,7 @@ class ArrayInterface {
|
||||
return func(reinterpret_cast<uint64_t const *>(data));
|
||||
}
|
||||
|
||||
XGBOOST_DEVICE size_t constexpr ElementSize() {
|
||||
XGBOOST_DEVICE size_t ElementSize() {
|
||||
return this->DispatchCall(
|
||||
[](auto *p_values) { return sizeof(std::remove_pointer_t<decltype(p_values)>); });
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user