/**
* Copy constructor.
*
- * You should really use the @p copy_triangulation function, so we declare
- * this function but let it throw an internal error. The reason for this is
+ * You should really use the @p copy_triangulation function, so this
+ * constructor is deleted. The reason for this is
* that we may want to use triangulation objects in collections. However,
* C++ containers require that the objects stored in them are copyable, so
* we need to provide a copy constructor. On the other hand, copying
* Finally, through the exception, one easily finds the places where code
* has to be changed to avoid copies.
*/
- Triangulation (const Triangulation<dim, spacedim> &t);
+ Triangulation (const Triangulation<dim, spacedim> &) = delete;
/**
* Move constructor.
}
-template <int dim, int spacedim>
-Triangulation<dim, spacedim>::
-Triangulation (const Triangulation<dim, spacedim> &other)
-// do not set any subscriptors;
-// anyway, calling this constructor
-// is an error!
- :
- Subscriptor(),
- signals (),
- anisotropic_refinement(false),
- check_for_distorted_cells(other.check_for_distorted_cells)
-{
- Assert (false, ExcMessage ("You are not allowed to call this constructor "
- "because copying Triangulation objects is not "
- "allowed. Use Triangulation::copy_triangulation() "
- "instead."));
-}
-
-
template <int dim, int spacedim>
Triangulation<dim, spacedim>::