[Dune] [#584] Replace SmartPointer by shared_ptr

Oswald Benedikt Benedikt.Oswald at psi.ch
Mon Oct 26 11:06:30 CET 2009


Hi, I just checked out dune / head (newest version), it now crashes here:


mpicxx -DHAVE_CONFIG_H -I.  -I/Users/oswald/svnwork/dune-trunk/dune-common -I/Users/oswald/svnwork/dune-trunk/dune-grid -I. -DMPICH_IGNORE_CXX_SEEK -DGRIDDIM=3 -D_REENTRANT -I/Users/oswald/extlib/openmpi-1.3.3/include -DMPIPP_H -DENABLE_MPI=1 -DMPICH_IGNORE_CXX_SEEK -DGRIDDIM=3  -I/Users/oswald/svnwork/dune-trunk/dune-common -I/Users/oswald/extlib/ALUGrid-1.14/include -I/Users/oswald/extlib/ALUGrid-1.14/include/serial -I/Users/oswald/extlib/ALUGrid-1.14/include/duneinterface -DENABLE_ALUGRID -I/Users/oswald/extlib/ALUGrid-1.14/include/parallel -I/Users/oswald/svnwork/dune-trunk/dune-grid -DMPICH_IGNORE_CXX_SEEK -DGRIDDIM=3 -MT visualization-visualization.o -MD -MP -MF .deps/visualization-visualization.Tpo -c -o visualization-visualization.o `test -f 'visualization.cc' || echo './'`visualization.cc
/Users/oswald/svnwork/dune-trunk/dune-grid/dune/grid/io/file/vtk/vtkwriter.hh: In member function 'void Dune::VTKWriter<GridView>::addVertexData(const V&, std::string) [with V = std::vector<double, std::allocator<double> >, GridView = Dune::GridView<Dune::DefaultLeafGridViewTraits<const Dune::SGrid<3, 3, double>, All_Partition> >]':
vertexdata.hh:51:   instantiated from 'void vertexdata(const G&, const F&) [with G = Dune::SGrid<3, 3, double>, F = Exp<double, 3>]'
visualization.cc:35:   instantiated from 'void dowork(Grid&, int) [with Grid = Dune::SGrid<3, 3, double>]'
visualization.cc:65:   instantiated from here
/Users/oswald/svnwork/dune-trunk/dune-grid/dune/grid/io/file/vtk/vtkwriter.hh:642: error: no matching function for call to 'std::list<std::tr1::shared_ptr<Dune::VTKFunction<Dune::SGrid<3, 3, double> > >, std::allocator<std::tr1::shared_ptr<Dune::VTKFunction<Dune::SGrid<3, 3, double> > > > >::push_back(Dune::VTKFunction<Dune::SGrid<3, 3, double> >*&)'
/usr/include/c++/4.0.0/bits/stl_list.h:772: note: candidates are: void std::list<_Tp, _Alloc>::push_back(const _Tp&) [with _Tp = std::tr1::shared_ptr<Dune::VTKFunction<Dune::SGrid<3, 3, double> > >, _Alloc = std::allocator<std::tr1::shared_ptr<Dune::VTKFunction<Dune::SGrid<3, 3, double> > > >]
/Users/oswald/svnwork/dune-trunk/dune-grid/dune/grid/io/file/vtk/vtkwriter.hh: In member function 'void Dune::VTKWriter<GridView>::addVertexData(const V&, std::string) [with V = std::vector<double, std::allocator<double> >, GridView = Dune::GridView<Dune::DefaultLeafGridViewTraits<const Dune::ALUSimplexGrid<3, 3>, All_Partition> >]':
vertexdata.hh:51:   instantiated from 'void vertexdata(const G&, const F&) [with G = Dune::ALUSimplexGrid<3, 3>, F = Exp<double, 3>]'
visualization.cc:35:   instantiated from 'void dowork(Grid&, int) [with Grid = Dune::ALUSimplexGrid<3, 3>]'
visualization.cc:69:   instantiated from here
/Users/oswald/svnwork/dune-trunk/dune-grid/dune/grid/io/file/vtk/vtkwriter.hh:642: error: no matching function for call to 'std::list<std::tr1::shared_ptr<Dune::VTKFunction<Dune::ALUSimplexGrid<3, 3> > >, std::allocator<std::tr1::shared_ptr<Dune::VTKFunction<Dune::ALUSimplexGrid<3, 3> > > > >::push_back(Dune::VTKFunction<Dune::ALUSimplexGrid<3, 3> >*&)'
/usr/include/c++/4.0.0/bits/stl_list.h:772: note: candidates are: void std::list<_Tp, _Alloc>::push_back(const _Tp&) [with _Tp = std::tr1::shared_ptr<Dune::VTKFunction<Dune::ALUSimplexGrid<3, 3> > >, _Alloc = std::allocator<std::tr1::shared_ptr<Dune::VTKFunction<Dune::ALUSimplexGrid<3, 3> > > >]
/Users/oswald/svnwork/dune-trunk/dune-grid/dune/grid/io/file/vtk/vtkwriter.hh: In member function 'void Dune::VTKWriter<GridView>::addVertexData(const V&, std::string) [with V = std::vector<double, std::allocator<double> >, GridView = Dune::GridView<Dune::DefaultLeafGridViewTraits<const Dune::ALUCubeGrid<3, 3>, All_Partition> >]':
vertexdata.hh:51:   instantiated from 'void vertexdata(const G&, const F&) [with G = Dune::ALUCubeGrid<3, 3>, F = Exp<double, 3>]'
visualization.cc:35:   instantiated from 'void dowork(Grid&, int) [with Grid = Dune::ALUCubeGrid<3, 3>]'
visualization.cc:73:   instantiated from here
/Users/oswald/svnwork/dune-trunk/dune-grid/dune/grid/io/file/vtk/vtkwriter.hh:642: error: no matching function for call to 'std::list<std::tr1::shared_ptr<Dune::VTKFunction<Dune::ALUCubeGrid<3, 3> > >, std::allocator<std::tr1::shared_ptr<Dune::VTKFunction<Dune::ALUCubeGrid<3, 3> > > > >::push_back(Dune::VTKFunction<Dune::ALUCubeGrid<3, 3> >*&)'
/usr/include/c++/4.0.0/bits/stl_list.h:772: note: candidates are: void std::list<_Tp, _Alloc>::push_back(const _Tp&) [with _Tp = std::tr1::shared_ptr<Dune::VTKFunction<Dune::ALUCubeGrid<3, 3> > >, _Alloc = std::allocator<std::tr1::shared_ptr<Dune::VTKFunction<Dune::ALUCubeGrid<3, 3> > > >]
make[2]: *** [visualization-visualization.o] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2
--- Failed to build dune-grid-howto ---
Execution of dunecontrol terminated due to errors!



------------------------------------------------------------------------------------------------------------------
Benedikt Oswald, Dr. sc. techn., dipl. El. Ing. ETH, www.psi.ch, Computational Accelerator Scientist
Paul Scherrer  Institute (PSI), CH-5232 Villigen, Suisse, benedikt.oswald at psi.ch, +41(0)56 310 32 12
"Passion is required for any great work, and for the Revolution passion and audacity are required in big doses.", 
Ernesto 'Che' Guevara, Letter to his parents.
http://maxwell.psi.ch/amaswiki/index.php/User:BenediktOswald 
------------------------------------------------------------------------------------------------------------------




-----Original Message-----
From: dune-bounces+benedikt.oswald=psi.ch at dune-project.org on behalf of Dune
Sent: Mon 26.10.2009 11:02
To: dune at dune-project.org
Subject: [Dune] [#584] Replace SmartPointer by shared_ptr
 
THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.

The following task has a new comment added:

FS#584 - Replace SmartPointer by shared_ptr
User who did this - Oliver Sander (sander)

----------
@Benedikt: just from looking at it I suspect it may be a missing implicit conversion from a plain pointer to a shared_ptr on whatever implementation you happen to use on your platform. Could you please upgrade vtkwriter.hh and try again?

Thanks
----------

More information can be found at the following URL:
http://www.dune-project.org/flyspray/index.php?do=details&task_id=584#comment1237

You are receiving this message because you have requested it from the Flyspray bugtracking system.  If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.

_______________________________________________
Dune mailing list
Dune at dune-project.org
http://lists.dune-project.org/mailman/listinfo/dune

-------------- next part --------------
A non-text attachment was scrubbed...
Name: winmail.dat
Type: application/ms-tnef
Size: 5121 bytes
Desc: not available
URL: <https://lists.dune-project.org/pipermail/dune/attachments/20091026/a0cf8de0/attachment.bin>


More information about the Dune mailing list