diff --git a/src/libhictk/cooler/include/hictk/cooler/impl/utils_rename_chroms_impl.hpp b/src/libhictk/cooler/include/hictk/cooler/impl/utils_rename_chroms_impl.hpp index 57dd7d0ec..8e59f6674 100644 --- a/src/libhictk/cooler/include/hictk/cooler/impl/utils_rename_chroms_impl.hpp +++ b/src/libhictk/cooler/include/hictk/cooler/impl/utils_rename_chroms_impl.hpp @@ -5,7 +5,7 @@ #pragma once #include -#include +#include #include #include @@ -54,7 +54,8 @@ template template inline void rename_chromosomes(std::string_view uri, It first_mapping, It last_mapping) { - return rename_chromosomes(uri, {first_mapping, last_mapping}); + return rename_chromosomes( + uri, phmap::btree_map{first_mapping, last_mapping}); } template diff --git a/test/units/cooler/utils_rename_chromosomes_test.cpp b/test/units/cooler/utils_rename_chromosomes_test.cpp index 2915ee45f..76602a7f8 100644 --- a/test/units/cooler/utils_rename_chromosomes_test.cpp +++ b/test/units/cooler/utils_rename_chromosomes_test.cpp @@ -5,6 +5,7 @@ #include #include #include +#include #include "hictk/cooler/cooler.hpp" #include "hictk/cooler/utils.hpp" @@ -21,7 +22,8 @@ TEST_CASE("Cooler: rename chromosomes", "[cooler][short]") { const Reference ref{{0, "chr1", 10}, {1, "chr2", 10}}; std::ignore = cooler::File::create(path.string(), ref, 1, true); - cooler::utils::rename_chromosomes(path.string(), {{"chr1", "1"}}); + cooler::utils::rename_chromosomes(path.string(), + std::map{{"chr1", "1"}}); { const auto chroms = cooler::File(path.string()).chromosomes();