From 1cbb7e8d5ae8d8b1b72e57eea4b1604027d44d9e Mon Sep 17 00:00:00 2001 From: Matthias Maier Date: Mon, 22 Apr 2019 14:32:19 -0500 Subject: [PATCH] improve error message --- source/lac/dynamic_sparsity_pattern.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/source/lac/dynamic_sparsity_pattern.cc b/source/lac/dynamic_sparsity_pattern.cc index b96163570f..5631edc661 100644 --- a/source/lac/dynamic_sparsity_pattern.cc +++ b/source/lac/dynamic_sparsity_pattern.cc @@ -358,7 +358,11 @@ DynamicSparsityPattern::exists(const size_type i, const size_type j) const { Assert(i < rows, ExcIndexRange(i, 0, rows)); Assert(j < cols, ExcIndexRange(j, 0, cols)); - Assert(rowset.size() == 0 || rowset.is_element(i), ExcInternalError()); + Assert( + rowset.size() == 0 || rowset.is_element(i), + ExcMessage( + "The row IndexSet does not contain the index i. This sparsity pattern " + "object cannot know whether the entry (i, j) exists or not.")); // Avoid a segmentation fault in below code if the row index happens to // not be present in the IndexSet rowset: -- 2.39.5