Skip to content

Commit

Permalink
Move template specialization out of class definition.
Browse files Browse the repository at this point in the history
  • Loading branch information
kris-rowe committed Jul 26, 2024
1 parent ee42913 commit a502fbd
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions include/occa/core/memoryPool.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -215,12 +215,6 @@ namespace occa {
template <class T = void>
occa::memory reserve(const dim_t entries);


// Need to declare this function template specialization
// in the header so it is available in other translation units.
template <>
occa::memory reserve<void>(const dim_t entries);

/**
* @startDoc{reserve[1]}
*
Expand Down Expand Up @@ -257,6 +251,10 @@ namespace occa {
void setAlignment(const udim_t alignment);
};

// Need to declare this function template specialization
// in the header so it is available in other translation units.
template <>
occa::memory memoryPool::reserve<void>(const dim_t entries);
}

#include "memoryPool.tpp"
Expand Down

0 comments on commit a502fbd

Please sign in to comment.