diff --git a/src/abismal.cpp b/src/abismal.cpp index d87c92f..c0cb01b 100644 --- a/src/abismal.cpp +++ b/src/abismal.cpp @@ -1067,7 +1067,7 @@ struct paired_end_mapping_statistics { return oss.str(); } NLOHMANN_DEFINE_TYPE_INTRUSIVE(paired_end_mapping_statistics, read_pair_stats, - end1_stats, end2_stats); + end1_stats, end2_stats) }; static void diff --git a/src/simreads.cpp b/src/simreads.cpp index 592e91e..d00fd67 100644 --- a/src/simreads.cpp +++ b/src/simreads.cpp @@ -81,6 +81,7 @@ rand_double() -> double { // ADS: in the interval [0, 1] static inline auto format_fastq_record(const std::string &name, const std::string &read) -> std::string { + static constexpr auto assumed_quality_score = 63; assert(!name.empty()); std::string s; s += '@'; @@ -88,7 +89,7 @@ format_fastq_record(const std::string &name, s += '\n'; s += read; s += "\n+\n"; - s += std::string(std::size(read), 'B'); + s += std::string(std::size(read), assumed_quality_score); return s; } @@ -283,7 +284,7 @@ sim_frag_position(const std::string &genome, const std::size_t frag_len, // NOLINTBEGIN(*-narrowing-conversions) the_frag = std::string(g_beg + the_posn, g_beg + the_posn + frag_len); while (require_valid && - std::all_of(std::cbegin(the_frag), std::cend(the_frag), is_valid)) { + !std::all_of(std::cbegin(the_frag), std::cend(the_frag), is_valid)) { the_posn = simreads_random::rand() % lim; the_frag = std::string(g_beg + the_posn, g_beg + the_posn + frag_len); }