dolfin team mailing list archive
-
dolfin team
-
Mailing list archive
-
Message #17725
Mesh refinement copying problems
There seems to be a problem with the new approach to mesh refinement
(return by value).
Try the following simple test (in Python):
mesh = UnitSquare(3, 3)
new_mesh = refine(mesh)
This generates the following output:
Mesh empty constructor: this = 11fb880
Mesh empty constructor: this = c03f63c0
Calling uniform refinement free function: mesh = 11fb880
Mesh empty constructor: this = c03f6160
Mesh assignment operator: this = c03f63c0
Mesh destructor: this = c03f6160
Mesh copy constructor: this = 21eefb0
Mesh assignment operator: this = 21eefb0
Mesh destructor: this = c03f63c0
Mesh destructor: this = 21eefb0
Mesh destructor: this = 11fb880
I would have expected to see two constructors, two destructors and
zero copy constructors, but one extra mesh seems to be created.
--
Anders
Attachment:
signature.asc
Description: Digital signature
Follow ups