From: Wolfgang Bangerth Date: Fri, 27 Feb 2015 02:58:51 +0000 (-0600) Subject: Replace an exception without argument. X-Git-Tag: v8.3.0-rc1~411^2~4 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b6a735fb1ac081c5e37d612939167c7a2b09e2ac;p=dealii.git Replace an exception without argument. In this case, the exception is really an internal error that indicates an inconsistent state of our data structures. There isn't really a good reason to not use ExcMessage with some descriptive text. --- diff --git a/source/grid/tria.cc b/source/grid/tria.cc index d181fb2135..62398b0e9c 100644 --- a/source/grid/tria.cc +++ b/source/grid/tria.cc @@ -931,11 +931,6 @@ namespace internal << "Something went wrong when making cell " << arg1 << ". Read the docs and the source code " << "for more information."); - /** - * Exception - * @ingroup Exceptions - */ - DeclException0 (ExcGridHasInvalidVertices); /** * Exception * @ingroup Exceptions @@ -1692,7 +1687,10 @@ namespace internal // exit with an exception AssertThrow (* (std::min_element(vertex_touch_count.begin(), vertex_touch_count.end())) >= 2, - ExcGridHasInvalidVertices()); + ExcMessage("During creation of a triangulation, a part of the " + "algorithm encountered a vertex that is part of only " + "a single adjacent line. However, in 2d, every vertex " + "needs to be at least part of two lines.")); } // reserve enough space @@ -2009,7 +2007,10 @@ namespace internal // exit with an exception AssertThrow (* (std::min_element(vertex_touch_count.begin(), vertex_touch_count.end())) >= 3, - ExcGridHasInvalidVertices()); + ExcGridHasInvalidVertices("During creation of a triangulation, a part of the " + "algorithm encountered a vertex that is part of only " + "one or two adjacent lines. However, in 3d, every vertex " + "needs to be at least part of three lines.")); }