From 9cac1f228d8e04879b52ea1c14bd0642bf4502ee Mon Sep 17 00:00:00 2001 From: Wolfgang Bangerth Date: Wed, 8 Apr 2009 12:42:29 +0000 Subject: [PATCH] Remove a bunch of checks of the form unsigned_variable >= 0 as we get warnings about these. git-svn-id: https://svn.dealii.org/trunk@18568 0785d39b-7218-0410-832d-ea1e28bc413d --- .../lac/include/lac/constraint_matrix.templates.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/deal.II/lac/include/lac/constraint_matrix.templates.h b/deal.II/lac/include/lac/constraint_matrix.templates.h index 63bd4d2a4f..cb1618a76a 100644 --- a/deal.II/lac/include/lac/constraint_matrix.templates.h +++ b/deal.II/lac/include/lac/constraint_matrix.templates.h @@ -1286,13 +1286,13 @@ distribute_local_to_global (const FullMatrix &local_matrix, // element is zero. if (have_indirect_rows == false) { - Assert(loc_row >= 0 && loc_row < n_local_dofs, + Assert(loc_row < n_local_dofs, ExcInternalError()); for (unsigned int j=0; j < n_actual_dofs; ++j) { const unsigned int loc_col = my_indices[j].local_row; - Assert(loc_col >= 0 && loc_col < n_local_dofs, + Assert(loc_col < n_local_dofs, ExcInternalError()); if (local_matrix(loc_row,loc_col) != 0) @@ -1332,14 +1332,14 @@ distribute_local_to_global (const FullMatrix &local_matrix, // local matrix if (loc_row != deal_II_numbers::invalid_unsigned_int) { - Assert (loc_row >= 0 && loc_row < n_local_dofs, + Assert (loc_row < n_local_dofs, ExcInternalError()); // case 1a: col has direct contribution // in local matrix if (loc_col != deal_II_numbers::invalid_unsigned_int) { - Assert (loc_col >= 0 && loc_col < n_local_dofs, + Assert (loc_col < n_local_dofs, ExcInternalError()); col_val = local_matrix(loc_row,loc_col); } @@ -1371,7 +1371,7 @@ distribute_local_to_global (const FullMatrix &local_matrix, double add_this; if (loc_col != deal_II_numbers::invalid_unsigned_int) { - Assert (loc_col >= 0 && loc_col < n_local_dofs, + Assert (loc_col < n_local_dofs, ExcInternalError()); add_this = local_matrix(my_indices[i].constraints[q].first, loc_col); @@ -1411,7 +1411,7 @@ distribute_local_to_global (const FullMatrix &local_matrix, { if (loc_row != deal_II_numbers::invalid_unsigned_int) { - Assert (loc_row >= 0 && loc_row < n_local_dofs, + Assert (loc_row < n_local_dofs, ExcInternalError()); val = local_vector(loc_row); for (unsigned int i=0; i