mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-29 14:00:49 +03:00
0028355: Stating wrong parent class in DEFINE_STANDARD_RTTIEXT is not recognized during compilation
Added compile-time checks (static_assert) in DEFINE_STANDARD_RTTI*(A,B) macros to check that A is actually the class being defined, and B is its base class. For GCC compiler version 4.7 and later on, check ensures that B is direct base class of A. Fixed dubious RTTI definitions.
This commit is contained in:
@@ -30,7 +30,7 @@ public:
|
||||
// Execution.
|
||||
virtual Standard_Integer Execute(Handle(TFunction_Logbook)& log) const;
|
||||
|
||||
DEFINE_STANDARD_RTTIEXT(CircleDriver, TFunction_Driver)
|
||||
DEFINE_STANDARD_RTTIEXT(CircleDriver, BaseDriver)
|
||||
};
|
||||
|
||||
#endif // !defined(_CIRCLEDRIVER_H_)
|
||||
|
@@ -30,7 +30,7 @@ public:
|
||||
// Execution.
|
||||
virtual Standard_Integer Execute(Handle(TFunction_Logbook)& log) const;
|
||||
|
||||
DEFINE_STANDARD_RTTIEXT(ConeDriver, TFunction_Driver)
|
||||
DEFINE_STANDARD_RTTIEXT(ConeDriver, BaseDriver)
|
||||
};
|
||||
|
||||
#endif // !defined(_CONEDRIVER_H_)
|
||||
|
@@ -30,7 +30,7 @@ public:
|
||||
// Execution.
|
||||
virtual Standard_Integer Execute(Handle(TFunction_Logbook)& log) const;
|
||||
|
||||
DEFINE_STANDARD_RTTIEXT(CylinderDriver, TFunction_Driver)
|
||||
DEFINE_STANDARD_RTTIEXT(CylinderDriver, BaseDriver)
|
||||
};
|
||||
|
||||
#endif // !defined(_CYLINDERDRIVER_H_)
|
||||
|
@@ -30,7 +30,7 @@ public:
|
||||
// Execution.
|
||||
virtual Standard_Integer Execute(Handle(TFunction_Logbook)& log) const;
|
||||
|
||||
DEFINE_STANDARD_RTTIEXT(PointDriver, TFunction_Driver)
|
||||
DEFINE_STANDARD_RTTIEXT(PointDriver, BaseDriver)
|
||||
};
|
||||
|
||||
#endif // !defined(_PointDRIVER_H_)
|
||||
|
@@ -30,7 +30,7 @@ public:
|
||||
// Execution.
|
||||
virtual Standard_Integer Execute(Handle(TFunction_Logbook)& log) const;
|
||||
|
||||
DEFINE_STANDARD_RTTIEXT(PrismDriver, TFunction_Driver)
|
||||
DEFINE_STANDARD_RTTIEXT(PrismDriver, BaseDriver)
|
||||
};
|
||||
|
||||
#endif // !defined(_PRISMDRIVER_H_)
|
||||
|
@@ -30,7 +30,7 @@ public:
|
||||
// Execution.
|
||||
virtual Standard_Integer Execute(Handle(TFunction_Logbook)& log) const;
|
||||
|
||||
DEFINE_STANDARD_RTTIEXT(ShapeSaverDriver, TFunction_Driver)
|
||||
DEFINE_STANDARD_RTTIEXT(ShapeSaverDriver, BaseDriver)
|
||||
};
|
||||
|
||||
#endif // !defined(_SHAPESAVERDRIVER_H_)
|
||||
|
Reference in New Issue
Block a user