Skip to content

Commit

Permalink
Address clang-tidy warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
robomics committed Oct 10, 2024
1 parent d1f4f9a commit e53f4b1
Show file tree
Hide file tree
Showing 10 changed files with 12 additions and 12 deletions.
6 changes: 3 additions & 3 deletions src/hictk/cli/cli_balance.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ void Cli::transform_args_ice_balance_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;
}

void Cli::transform_args_scale_balance_subcommand() {
Expand Down Expand Up @@ -454,7 +454,7 @@ void Cli::transform_args_scale_balance_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;
}

void Cli::transform_args_vc_balance_subcommand() {
Expand All @@ -479,7 +479,7 @@ void Cli::transform_args_vc_balance_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;
}

} // namespace hictk::tools
2 changes: 1 addition & 1 deletion src/hictk/cli/cli_convert.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -280,7 +280,7 @@ void Cli::transform_args_convert_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;

if (sc.get_option("--compression-lvl")->empty()) {
c.compression_lvl =
Expand Down
2 changes: 1 addition & 1 deletion src/hictk/cli/cli_dump.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ void Cli::transform_args_dump_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;

c.format = infer_input_format(c.uri);
if (c.format == "hic" && c.resolution == 0 && c.table == "chroms") {
Expand Down
2 changes: 1 addition & 1 deletion src/hictk/cli/cli_fix_mcool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ void Cli::transform_args_fix_mcool_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;
}

} // namespace hictk::tools
2 changes: 1 addition & 1 deletion src/hictk/cli/cli_load.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -273,7 +273,7 @@ void Cli::transform_args_load_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;
}

} // namespace hictk::tools
2 changes: 1 addition & 1 deletion src/hictk/cli/cli_merge.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ void Cli::transform_args_merge_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;
}

} // namespace hictk::tools
2 changes: 1 addition & 1 deletion src/hictk/cli/cli_metadata.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ void Cli::transform_args_metadata_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;
}

} // namespace hictk::tools
2 changes: 1 addition & 1 deletion src/hictk/cli/cli_rename_chromosomes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ void Cli::transform_args_rename_chromosomes_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;
}

} // namespace hictk::tools
2 changes: 1 addition & 1 deletion src/hictk/cli/cli_validate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ void Cli::transform_args_validate_subcommand() {
} else {
// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/hictk/cli/cli_zoomify.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ void Cli::transform_args_zoomify_subcommand() {

// in spdlog, high numbers correspond to low log levels
assert(c.verbosity > 0 && c.verbosity < 5);
c.verbosity = static_cast<std::uint8_t>(spdlog::level::critical) - c.verbosity;
c.verbosity = static_cast<std::int16_t>(spdlog::level::critical) - c.verbosity;

c.input_format = infer_input_format(c.path_to_input);
c.output_format = infer_output_format(c.path_to_output);
Expand Down

0 comments on commit e53f4b1

Please sign in to comment.