Skip to content

Commit

Permalink
Merge pull request #3252 from eseiler/fix/include
Browse files Browse the repository at this point in the history
[FIX] Missing include
  • Loading branch information
eseiler authored May 7, 2024
2 parents f489f67 + ff16276 commit bcc142e
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 2 deletions.
1 change: 1 addition & 0 deletions include/seqan3/io/sam_file/format_bam.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

#include <seqan3/alphabet/nucleotide/dna16sam.hpp>
#include <seqan3/core/debug_stream/optional.hpp>
#include <seqan3/core/debug_stream/tuple.hpp>
#include <seqan3/io/sam_file/detail/cigar.hpp>
#include <seqan3/io/sam_file/detail/format_sam_base.hpp>
#include <seqan3/io/sam_file/header.hpp>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ class interleaved_bloom_filter

class membership_agent_type; // documented upon definition below

template <std::integral value_t>
template <typename value_t>
class counting_agent_type; // documented upon definition below

/*!\name Constructors, destructor and assignment
Expand Down Expand Up @@ -960,10 +960,12 @@ class counting_vector : public std::vector<value_t>
* \include test/snippet/search/dream_index/counting_agent.cpp
*/
template <data_layout data_layout_mode>
template <std::integral value_t>
template <typename value_t>
class interleaved_bloom_filter<data_layout_mode>::counting_agent_type
{
private:
static_assert(std::integral<value_t>, "The value type must model std::integral.");

//!\brief The type of the augmented seqan3::interleaved_bloom_filter.
using ibf_t = interleaved_bloom_filter<data_layout_mode>;

Expand Down
1 change: 1 addition & 0 deletions test/unit/io/sam_file/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
seqan3_test (format_bam_test.cpp CYCLIC_DEPENDING_INCLUDES include-seqan3-io-sam_file-format_sam.hpp)
seqan3_test (format_sam_test.cpp CYCLIC_DEPENDING_INCLUDES include-seqan3-io-sam_file-format_bam.hpp)
seqan3_test (sam_file_input_test.cpp)
seqan3_test (sam_file_output_include_test.cpp)
seqan3_test (sam_file_output_test.cpp)
seqan3_test (sam_file_record_test.cpp)
seqan3_test (sam_file_seek_test.cpp)
Expand Down
26 changes: 26 additions & 0 deletions test/unit/io/sam_file/sam_file_output_include_test.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
// SPDX-FileCopyrightText: 2006-2024 Knut Reinert & Freie Universität Berlin
// SPDX-FileCopyrightText: 2016-2024 Knut Reinert & MPI für molekulare Genetik
// SPDX-License-Identifier: BSD-3-Clause

#include <gtest/gtest.h>

// seqan3/io/sam_file/format_bam.hpp did not include core/debug_stream/tuple.hpp
// having only the following include leads to a compile error
#include <seqan3/io/sam_file/output.hpp>

TEST(sam_file_output, include)
{
using sam_file_output_t = seqan3::sam_file_output<seqan3::fields<seqan3::field::id>,
seqan3::type_list<seqan3::format_sam, seqan3::format_bam>,
std::vector<std::string>>;
std::string buffer{};
std::ostringstream stream{buffer};
{
sam_file_output_t out{stream, std::vector<std::string>{}, std::vector<size_t>{}, seqan3::format_sam{}};
out.emplace_back(std::string{});
}
{
sam_file_output_t out{stream, std::vector<std::string>{}, std::vector<size_t>{}, seqan3::format_bam{}};
out.emplace_back(std::string{});
}
}

0 comments on commit bcc142e

Please sign in to comment.