Open bangerth opened 4 years ago
@bangerth I see you have two merged pull requests related to this. Has this issue been addressed?
It seems to me like the majority of places has been converted. But there are a few places one could still touch:
> egrep -n -r 'for.*typename' source/
source/postprocess/heating_statistics.cc:100: for (typename std::list<std::unique_ptr<HeatingModel::Interface<dim>>>::const_iterator
source/postprocess/heating_statistics.cc:122: for (typename std::list<std::unique_ptr<HeatingModel::Interface<dim>>>::const_iterator
source/postprocess/visualization.cc:1176: for (typename std::list<typename aspect::internal::Plugins::PluginList<VisualizationPostprocessors::Interface<dim>>::PluginInfo>::const_iterator
source/postprocess/visualization/heating.cc:153: for (typename std::list<std::unique_ptr<HeatingModel::Interface<dim>>>::const_iterator
source/postprocess/interface.cc:234: for (typename std::list<typename aspect::internal::Plugins::PluginList<Interface<dim>>::PluginInfo>::const_iterator
source/simulator/core.cc:1626: for (typename Triangulation<dim>::active_cell_iterator
source/simulator/core.cc:1641: for (typename Triangulation<dim>::active_cell_iterator
source/termination_criteria/interface.cc:87: for (typename std::list<std::unique_ptr<Interface<dim>>>::const_iterator
source/particle/interpolator/bilinear_least_squares.cc:115: for (typename ParticleHandler<dim>::particle_iterator particle = particle_range.begin();
source/particle/interpolator/bilinear_least_squares.cc:195: for (typename std::vector<Point<dim>>::const_iterator itr = positions.begin(); itr != positions.end(); ++itr, ++positions_index)
source/particle/interpolator/nearest_neighbor.cc:76: for (typename ParticleHandler<dim>::particle_iterator particle = particle_range.begin();
source/particle/interpolator/quadratic_least_squares.cc:102: for (typename ParticleHandler<dim>::particle_iterator particle = particle_range.begin();
source/particle/interpolator/quadratic_least_squares.cc:161: for (typename std::vector<Point<dim>>::const_iterator itr = positions.begin(); itr != positions.end(); ++itr, ++index_positions)
source/particle/integrator/euler.cc:46: for (typename ParticleHandler<dim>::particle_iterator it = begin_particle;
source/particle/integrator/rk_2.cc:73: for (typename ParticleHandler<dim>::particle_iterator it = begin_particle;
source/particle/integrator/rk_4.cc:78: for (typename ParticleHandler<dim>::particle_iterator it = begin_particle;
source/particle/property/interface.cc:413: for (typename std::list<std::unique_ptr<Interface<dim>>>::const_iterator
source/particle/property/interface.cc:562: for (typename std::list<std::unique_ptr<Interface<dim>>>::const_iterator
source/particle/property/interface.cc:752: for (typename std::list<typename aspect::internal::Plugins::PluginList<aspect::Particle::Property::Interface<dim>>::PluginInfo>::const_iterator
source/particle/world.cc:465: for (typename ParticleHandler<dim>::particle_iterator it = begin_particle; it!=end_particle; ++it)
source/geometry_model/two_merged_chunks.cc:125: for (typename Triangulation<dim>::active_cell_iterator
source/mesh_refinement/interface.cc:156: for (typename std::list<std::unique_ptr<Interface<dim>>>::const_iterator
@pmbremner Feel free to convert these in whatever large or small increment you feel like.
We have a lot of places of the form
But using C++11 features, we can more easily write this as
Similarly, there are plenty of places of the form (or in many variations -- searching for
for... ::const_iterator
will yield many)that could now be written as
All of these might make the code simpler to read.