]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Bugfix: Remove ambiguity.
authorMatthias Maier <tamiko@43-1.org>
Mon, 7 Sep 2015 01:28:14 +0000 (20:28 -0500)
committerMatthias Maier <tamiko@43-1.org>
Mon, 7 Sep 2015 18:36:23 +0000 (13:36 -0500)
With the rest of Tensor<0,dim,Number>'s interface this operator= is
redundant.

include/deal.II/base/tensor_base.h

index 24fa78fded1ffaf9e46013f12cb7820f7d1aa302..9812c8341bb67521f7c064ffa3849589aaf70d16 100644 (file)
@@ -176,11 +176,6 @@ public:
   template <typename OtherNumber>
   Tensor<0,dim,Number> &operator = (const Tensor<0,dim,OtherNumber> &rhs);
 
-  /**
-   * Assignment operator.
-   */
-  Tensor<0,dim,Number> &operator = (const Number d);
-
   /**
    * Test for equality of two tensors.
    */
@@ -689,17 +684,6 @@ Tensor<0,dim,Number> &Tensor<0,dim,Number>::operator = (const Tensor<0,dim,Other
 }
 
 
-template <int dim, typename Number>
-inline
-Tensor<0,dim,Number> &Tensor<0,dim,Number>::operator = (const Number d)
-{
-  Assert(dim != 0 || d == OtherNumber(),
-         ExcMessage("Cannot assign a non-zero scalar to a Tensor<0,0,Number> object."));
-  value = d;
-  return *this;
-}
-
-
 template <int dim, typename Number>
 template <typename OtherNumber>
 inline

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.