dolfin team mailing list archive
-
dolfin team
-
Mailing list archive
-
Message #16817
[Bug 453207] Re: Assigning a Function to another Function does not work.
** Changed in: dolfin
Status: Confirmed => Fix Committed
--
Assigning a Function to another Function does not work.
https://bugs.launchpad.net/bugs/453207
You received this bug notification because you are a member of DOLFIN
Team, which is subscribed to DOLFIN.
Status in DOLFIN: Fix Committed
Bug description:
There is an error when one wants to assign a Function to a new one:
Function copy = orig;
or
Function copy(orig);
raise both an error as
/scratch-second/priesen/FEniCS/build/include/boost/smart_ptr/shared_ptr.hpp:412:
typename boost::detail::shared_ptr_traits<T>::reference
boost::shared_ptr< <template-parameter-1-1> >::operator*() const [with T
= dolfin::GenericVector]: Assertion `px != 0' failed.
in
#3 0x00007f98fc291a09 in dolfin::Function::operator=
(this=0x7fff047d2810, v=@0x7fff047d29c0) at
/scratch-second/priesen/FEniCS/build/include/boost/smart_ptr/shared_ptr.hpp:412
#4 0x00007f98fc291d09 in Function (this=0x7fff047d2810,
v=@0x7fff047d29c0) at dolfin/function/Function.cpp:113
Workaround:
use
Function copy(V_orig);
copy.vector() = orig.vector();
References