0030448: Coding - add typo detection to derivation creation methods using Standard_NO...
authorBenjamin Bihler <benjamin.bihler@compositence.de>
Mon, 25 Feb 2019 09:52:01 +0000 (12:52 +0300)
committerapn <apn@opencascade.com>
Wed, 27 Feb 2019 16:59:07 +0000 (19:59 +0300)
commit0be7dbe18320cd58be4ac0472ecfac9b473c6bf1
tree24a57814459e5f06c9ee51e92100256763f340b7
parent1c8fc6bee2656bc89332e8a3ad61b855480c557e
0030448: Coding - add typo detection to derivation creation methods using Standard_NODISCARD attribute

Added macro Standard_NODISCARD equivalent to C++17 attribute [[nodiscard]] for compilers that support this.
Using Standard_NODISCARD macro for methods that create new object in gp, math, Geom, Bnd packages.
Marked equivalent operators with Standard_NODISCARD, if they are defined close to relevant methods.

Corrected code where warnings on unused result of calls to methods creating new objects are generated.
In most cases it looks like spelling errors (e.g. Normalised() instead of Normalise())
70 files changed:
dox/resources/occt_rm.doxyfile
src/Bnd/Bnd_B2d.hxx
src/Bnd/Bnd_B2f.hxx
src/Bnd/Bnd_B3d.hxx
src/Bnd/Bnd_B3f.hxx
src/Bnd/Bnd_Box.hxx
src/Bnd/Bnd_Box2d.hxx
src/ChFi3d/ChFi3d_Builder_2.cxx
src/Contap/Contap_ArcFunction.cxx
src/Extrema/Extrema_ExtPElS.cxx
src/Geom/Geom_Axis1Placement.hxx
src/Geom/Geom_Curve.hxx
src/Geom/Geom_Geometry.hxx
src/Geom/Geom_Surface.hxx
src/Geom/Geom_Transformation.hxx
src/Geom/Geom_Vector.hxx
src/Geom/Geom_VectorWithMagnitude.hxx
src/Geom2d/Geom2d_AxisPlacement.hxx
src/Geom2d/Geom2d_Curve.hxx
src/Geom2d/Geom2d_Geometry.hxx
src/Geom2d/Geom2d_Transformation.hxx
src/Geom2d/Geom2d_Vector.hxx
src/Geom2d/Geom2d_VectorWithMagnitude.cxx
src/Geom2d/Geom2d_VectorWithMagnitude.hxx
src/GeomFill/GeomFill_GuideTrihedronPlan.cxx
src/GeomFill/GeomFill_TgtOnCoons.cxx
src/IntImpParGen/IntImpParGen.cxx
src/IntImpParGen/IntImpParGen_Tool.cxx
src/ShapeAnalysis/ShapeAnalysis_TransferParametersProj.cxx
src/Standard/Standard_Macro.hxx
src/TopLoc/TopLoc_Location.hxx
src/Units/Units_Token.hxx
src/gp/gp_Ax1.hxx
src/gp/gp_Ax2.hxx
src/gp/gp_Ax22d.hxx
src/gp/gp_Ax2d.hxx
src/gp/gp_Ax3.hxx
src/gp/gp_Circ.hxx
src/gp/gp_Circ2d.hxx
src/gp/gp_Cone.hxx
src/gp/gp_Cylinder.hxx
src/gp/gp_Dir.hxx
src/gp/gp_Dir2d.hxx
src/gp/gp_Elips.hxx
src/gp/gp_Elips2d.hxx
src/gp/gp_GTrsf.hxx
src/gp/gp_GTrsf2d.hxx
src/gp/gp_Hypr.hxx
src/gp/gp_Hypr2d.hxx
src/gp/gp_Lin.hxx
src/gp/gp_Lin2d.hxx
src/gp/gp_Mat.hxx
src/gp/gp_Mat2d.hxx
src/gp/gp_Parab.hxx
src/gp/gp_Parab2d.hxx
src/gp/gp_Pln.hxx
src/gp/gp_Pnt.hxx
src/gp/gp_Pnt2d.hxx
src/gp/gp_Quaternion.hxx
src/gp/gp_Sphere.hxx
src/gp/gp_Torus.hxx
src/gp/gp_Trsf.hxx
src/gp/gp_Trsf2d.hxx
src/gp/gp_Vec.hxx
src/gp/gp_Vec2d.hxx
src/gp/gp_XY.hxx
src/gp/gp_XYZ.hxx
src/math/math_IntegerVector.hxx
src/math/math_Matrix.hxx
src/math/math_Vector.hxx