From: wolf Date: Tue, 17 Jun 2003 15:03:18 +0000 (+0000) Subject: Strengthen an assertion. X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=31f3cd578e835c12a43e9cb7cea6486372f01ec3;p=dealii-svn.git Strengthen an assertion. git-svn-id: https://svn.dealii.org/trunk@7801 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/deal.II/source/numerics/vectors.cc b/deal.II/deal.II/source/numerics/vectors.cc index 1bf6f6a19d..7d40b46557 100644 --- a/deal.II/deal.II/source/numerics/vectors.cc +++ b/deal.II/deal.II/source/numerics/vectors.cc @@ -777,10 +777,11 @@ interpolate_boundary_values (const Mapping &mapping, const FiniteElement &fe = dof.get_fe(); const unsigned int n_components = fe.n_components(); const bool fe_is_system = (n_components != 1); - - Assert ((function_map.size() == 0) || - (n_components == function_map.begin()->second->n_components), - ExcInvalidFE()); + + for (typename FunctionMap::type::const_iterator i=function_map.begin(); + i!=function_map.end(); ++i) + Assert (n_components == i->second->n_components, + ExcInvalidFE()); // set the component mask to either // the original value or a vector