Make shape polymorphic
All checks were successful
Run tests / Explore-Gitea-Actions (push) Successful in 1m8s
Build Docs With Doxygen / Explore-Gitea-Actions (push) Successful in 29s

This commit is contained in:
2024-05-23 19:32:24 -04:00
parent 704a11cbc0
commit a2f1ea1979
2 changed files with 4 additions and 0 deletions

2
.gitignore vendored Normal file
View File

@@ -0,0 +1,2 @@
/cmake-build-debug
/.idea

View File

@@ -13,6 +13,7 @@ namespace J3ML::Geometry
class Shape class Shape
{ {
public: public:
virtual ~Shape() = default; //Polymorphic for dynamic_cast.
protected: protected:
private: private:
}; };
@@ -20,6 +21,7 @@ namespace J3ML::Geometry
class Shape2D class Shape2D
{ {
public: public:
virtual ~Shape2D() = default;
protected: protected:
private: private:
}; };