Skip to Content.
Sympa Menu

cgal-discuss - [cgal-discuss] Re: Constructors/Destructors

Subject: CGAL users discussion list

List archive

[cgal-discuss] Re: Constructors/Destructors


Chronological Thread 
  • From: rcco <>
  • To:
  • Subject: [cgal-discuss] Re: Constructors/Destructors
  • Date: Tue, 8 Jun 2010 06:22:48 -0700 (PDT)


First, thank you for your reply. I defined just like in the manual but
modified the My_face for my needs:

template <class Refs>
struct My_face : public CGAL::HalfedgeDS_face_base<Refs> {
CGAL::Color color;

My_face() {
printf("My_face!\n");
}
~My_face() {
printf("~My_face!\n");
}
};

but the output is:

My_face!
My_face!
~My_face!
My_face!
~My_face!
My_face!
~My_face!
My_face!
~My_face!
~My_face!
~My_face!
~My_face!
~My_face!
~My_face!

shouldn't be only 4 "My_face!" printed? And so many "~My_face!"? further
tests show the same for vertex and for halfedges the constructor is called
13 times and destructor prints out 37 messages! What am i doing wrong?

Thanks, Rodrigo

--
View this message in context:
http://cgal-discuss.949826.n4.nabble.com/Constructors-Destructors-tp2246412p2247371.html
Sent from the cgal-discuss mailing list archive at Nabble.com.



Archive powered by MHonArc 2.6.16.

Top of Page