From 7706301d3efaad51aa28fc167b5bac2f5bb7c7e7 Mon Sep 17 00:00:00 2001 From: conrad Date: Fri, 21 May 2021 15:21:38 +1000 Subject: [PATCH] reduce pedantic compiler warnings --- include/armadillo_bits/fn_as_scalar.hpp | 4 ++-- include/armadillo_bits/glue_times_meat.hpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/include/armadillo_bits/fn_as_scalar.hpp b/include/armadillo_bits/fn_as_scalar.hpp index 482de2e0..c4faf327 100644 --- a/include/armadillo_bits/fn_as_scalar.hpp +++ b/include/armadillo_bits/fn_as_scalar.hpp @@ -301,9 +301,9 @@ as_scalar(const Glue& X, const typename arma_not_cx::value == false) { - const sword N_mat = 1 + depth_lhs< glue_times, Glue >::num; + constexpr uword N_mat = 1 + depth_lhs< glue_times, Glue >::num; - arma_extra_debug_print(arma_str::format("N_mat = %d") % N_mat); + arma_extra_debug_print(arma_str::format("N_mat = %u") % N_mat); return as_scalar_redirect::apply(X); } diff --git a/include/armadillo_bits/glue_times_meat.hpp b/include/armadillo_bits/glue_times_meat.hpp index a2449998..416521bd 100644 --- a/include/armadillo_bits/glue_times_meat.hpp +++ b/include/armadillo_bits/glue_times_meat.hpp @@ -521,9 +521,9 @@ glue_times::apply(Mat& out, const Glue { arma_extra_debug_sigprint(); - const sword N_mat = 1 + depth_lhs< glue_times, Glue >::num; + constexpr uword N_mat = 1 + depth_lhs< glue_times, Glue >::num; - arma_extra_debug_print(arma_str::format("N_mat = %d") % N_mat); + arma_extra_debug_print(arma_str::format("N_mat = %u") % N_mat); glue_times_redirect::apply(out, X); }