From dfbd89147a38f51c483d72673e19ac46efa2c3ef Mon Sep 17 00:00:00 2001 From: Daniel Arndt Date: Fri, 17 Nov 2017 00:08:53 +0100 Subject: [PATCH] Remove (empty) default constructor for ArrayView --- .../incompatibilities/20171117DanielArndt | 4 ++ include/deal.II/base/array_view.h | 15 ------- tests/base/array_view_07.cc | 40 ------------------- tests/base/array_view_07.output | 2 - 4 files changed, 4 insertions(+), 57 deletions(-) create mode 100644 doc/news/changes/incompatibilities/20171117DanielArndt delete mode 100644 tests/base/array_view_07.cc delete mode 100644 tests/base/array_view_07.output diff --git a/doc/news/changes/incompatibilities/20171117DanielArndt b/doc/news/changes/incompatibilities/20171117DanielArndt new file mode 100644 index 0000000000..f913873ad5 --- /dev/null +++ b/doc/news/changes/incompatibilities/20171117DanielArndt @@ -0,0 +1,4 @@ +Removed: The default constructor for ArrayView was removed since +an object constructed in this way can't be used in any sensible way. +
+(Daniel Arndt, 2017/11/17) diff --git a/include/deal.II/base/array_view.h b/include/deal.II/base/array_view.h index dbeb9569b6..56a6b483a7 100644 --- a/include/deal.II/base/array_view.h +++ b/include/deal.II/base/array_view.h @@ -86,12 +86,6 @@ public: */ typedef const ElementType *const_iterator; - /** - * Default constructor. Creates an invalid view that does not point to - * anything at all. - */ - ArrayView (); - /** * Constructor. * @@ -244,15 +238,6 @@ private: //--------------------------------------------------------------------------- -template -inline -ArrayView::ArrayView() - : - starting_element (nullptr), - n_elements(0) -{} - - template inline diff --git a/tests/base/array_view_07.cc b/tests/base/array_view_07.cc deleted file mode 100644 index e32d512511..0000000000 --- a/tests/base/array_view_07.cc +++ /dev/null @@ -1,40 +0,0 @@ -// --------------------------------------------------------------------- -// -// Copyright (C) 2015 - 2016 by the deal.II authors -// -// This file is part of the deal.II library. -// -// The deal.II library is free software; you can use it, redistribute -// it, and/or modify it under the terms of the GNU Lesser General -// Public License as published by the Free Software Foundation; either -// version 2.1 of the License, or (at your option) any later version. -// The full text of the license can be found in the file LICENSE at -// the top level of the deal.II distribution. -// -// --------------------------------------------------------------------- - - -// test that a default-constructed ArrayView can actually be copied - -#include "../tests.h" - -#include - - -void test () -{ - ArrayView a; - ArrayView b = a; - - deallog << "OK" << std::endl; -} - - - - -int main() -{ - initlog(); - - test (); -} diff --git a/tests/base/array_view_07.output b/tests/base/array_view_07.output deleted file mode 100644 index 0fd8fc12f0..0000000000 --- a/tests/base/array_view_07.output +++ /dev/null @@ -1,2 +0,0 @@ - -DEAL::OK -- 2.39.5