Boost logo

Geometry :

Subject: [geometry] geometries design question: inheriting from STL containers
From: Tomislav Maric (tomislav.maric_at_[hidden])
Date: 2013-05-22 04:46:03


Hi everyone,

I'm learning about the boost.geometry implementation by analyzing the
sources.

I have a question regarding the Ring model. How come it inherits from a
(STL) Sequence?
Inheriting from STL containers is said to be a problem because of the
lack of a virtual destructor.
However, this is only dangerous if you try to use dynamic polymorphism
with a container, accessing
the derived container member functions using a base class container, but
why would anyone use
pointers to containers?

Best regards,
Tomislav


Geometry list run by mateusz at loskot.net