Skip to content

Commit dba632b

Browse files
fix clang compilation error
1 parent 3b85d48 commit dba632b

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

vpr/src/noc/noc_storage.h

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -317,12 +317,14 @@ class NocStorage {
317317
*
318318
* @tparam Container The type of standard library container used to carry
319319
* NoCLinkIds. This container type must be iterable in a range-based loop.
320+
* @tparam Ts Used to help clang infer correct template types. GCC can compile
321+
* without this extra template argument.
320322
* @param noc_link_ids A standard container that contains NoCLinkIds of the
321323
* requested NoC links
322324
* @return A const
323325
*/
324-
template <template<typename> class Container>
325-
const std::vector<std::reference_wrapper<const NocLink>>& get_noc_links(const Container<NocLinkId>& noc_link_ids) const;
326+
template <template<typename...> class Container, typename... Ts>
327+
const std::vector<std::reference_wrapper<const NocLink>>& get_noc_links(const Container<NocLinkId, Ts...>& noc_link_ids) const;
326328

327329

328330
/**
@@ -550,8 +552,8 @@ class NocStorage {
550552
};
551553

552554

553-
template <template<typename> class Container>
554-
const std::vector<std::reference_wrapper<const NocLink>>& NocStorage::get_noc_links(const Container<NocLinkId>& noc_link_ids) const {
555+
template <template<typename...> class Container, typename... Ts>
556+
const std::vector<std::reference_wrapper<const NocLink>>& NocStorage::get_noc_links(const Container<NocLinkId, Ts...>& noc_link_ids) const {
555557
returnable_noc_link_const_refs_.clear();
556558

557559
std::transform(noc_link_ids.begin(), noc_link_ids.end(), std::back_inserter(returnable_noc_link_const_refs_),

0 commit comments

Comments
 (0)