mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-04 13:13:25 +03:00
0027097: GCC and CLang compiler warnings and errors with -Wpedantic
Useless semicolons are removed after closing braces of namespaces and macros in code dependent on FreeImage and VTK. Comments added at the closing braces of namespaces to help comprehension. In OSD_File.cxx and OSD_Disk.cxx, unnecessary declarations of system functions are removed
This commit is contained in:
@@ -81,6 +81,6 @@ namespace Aspect_Convert
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
} // namespace Aspect_Convert
|
||||
|
||||
#endif /* _Aspect_Convert_HeaderFile */
|
||||
|
@@ -132,6 +132,7 @@ namespace BRepMesh
|
||||
//! Other data structures
|
||||
typedef std::pair<HArray1OfSegments, HBndBox2dTree> SegmentsTree;
|
||||
typedef NCollection_Array1<SegmentsTree> Array1OfSegmentsTree;
|
||||
}
|
||||
|
||||
} // namespace BRepMesh
|
||||
|
||||
#endif
|
||||
|
@@ -108,7 +108,7 @@ namespace {
|
||||
tmp_file->Remove();
|
||||
}
|
||||
|
||||
}
|
||||
} // anonymous namespace
|
||||
|
||||
// MKV 29.03.05
|
||||
#if ((TCL_MAJOR_VERSION > 8) || ((TCL_MAJOR_VERSION == 8) && (TCL_MINOR_VERSION >= 4))) && !defined(USE_NON_CONST)
|
||||
|
@@ -173,7 +173,7 @@ static const Font_FontMgr_FontAliasMapNode Font_FontMgr_MapOfFontsAliases[] =
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
} // anonymous namespace
|
||||
|
||||
#endif
|
||||
|
||||
|
@@ -76,7 +76,7 @@ static void ClearHighlightAndSelection (const Handle(ShapePipelineMap)& theMap,
|
||||
}
|
||||
}
|
||||
|
||||
vtkStandardNewMacro(IVtkDraw_Interactor);
|
||||
vtkStandardNewMacro(IVtkDraw_Interactor)
|
||||
|
||||
//===========================================================
|
||||
// Function : Constructor
|
||||
|
@@ -43,7 +43,8 @@ class IVtkDraw_Interactor : public vtkRenderWindowInteractor
|
||||
{
|
||||
public:
|
||||
static IVtkDraw_Interactor *New();
|
||||
vtkTypeMacro (IVtkDraw_Interactor, vtkRenderWindowInteractor);
|
||||
|
||||
vtkTypeMacro (IVtkDraw_Interactor, vtkRenderWindowInteractor)
|
||||
|
||||
virtual void Initialize();
|
||||
virtual void Enable();
|
||||
|
@@ -121,4 +121,5 @@ void InitShapeMapper (vtkMapper* theMapper, vtkLookupTable* theColorTable)
|
||||
theMapper->SetLookupTable (theColorTable);
|
||||
theMapper->Update();
|
||||
}
|
||||
};
|
||||
|
||||
} // namespace IVtkTools
|
||||
|
@@ -83,6 +83,6 @@ namespace IVtkTools
|
||||
Standard_EXPORT void InitShapeMapper (vtkMapper* theMapper,
|
||||
vtkLookupTable* theColorTable);
|
||||
|
||||
};
|
||||
}
|
||||
|
||||
#endif // IVtkTOOLS_H
|
||||
|
@@ -19,7 +19,7 @@
|
||||
#include <vtkInformationVector.h>
|
||||
#include <vtkObjectFactory.h>
|
||||
|
||||
vtkStandardNewMacro(IVtkTools_DisplayModeFilter);
|
||||
vtkStandardNewMacro(IVtkTools_DisplayModeFilter)
|
||||
|
||||
//============================================================================
|
||||
// Method: Constructor
|
||||
|
@@ -28,7 +28,8 @@
|
||||
class Standard_EXPORT IVtkTools_DisplayModeFilter : public IVtkTools_SubPolyDataFilter
|
||||
{
|
||||
public:
|
||||
vtkTypeMacro(IVtkTools_DisplayModeFilter,IVtkTools_SubPolyDataFilter);
|
||||
vtkTypeMacro(IVtkTools_DisplayModeFilter,IVtkTools_SubPolyDataFilter)
|
||||
|
||||
static IVtkTools_DisplayModeFilter *New();
|
||||
void PrintSelf (std::ostream& os, vtkIndent indent);
|
||||
|
||||
|
@@ -31,7 +31,7 @@
|
||||
#include <vtkTransform.h>
|
||||
#include <vtkTransformPolyDataFilter.h>
|
||||
|
||||
vtkStandardNewMacro(IVtkTools_ShapeDataSource);
|
||||
vtkStandardNewMacro(IVtkTools_ShapeDataSource)
|
||||
|
||||
//================================================================
|
||||
// Function : Constructor
|
||||
|
@@ -33,7 +33,8 @@ class IVtkTools_EXPORT IVtkTools_ShapeDataSource : public vtkPolyDataAlgorithm
|
||||
{
|
||||
public:
|
||||
|
||||
vtkTypeMacro(IVtkTools_ShapeDataSource, vtkPolyDataAlgorithm);
|
||||
vtkTypeMacro(IVtkTools_ShapeDataSource, vtkPolyDataAlgorithm)
|
||||
|
||||
static IVtkTools_ShapeDataSource* New();
|
||||
|
||||
|
||||
|
@@ -121,7 +121,7 @@ void IVtkTools_ShapeObject::SetShapeSource (IVtkTools_ShapeDataSource* theDataSo
|
||||
|
||||
//! @class IVtkTools_ShapeObject
|
||||
//! @brief VTK holder class for OCC shapes to pass them through pipelines.
|
||||
vtkStandardNewMacro(IVtkTools_ShapeObject);
|
||||
vtkStandardNewMacro(IVtkTools_ShapeObject)
|
||||
|
||||
//============================================================================
|
||||
// Method: Constructor
|
||||
|
@@ -37,7 +37,7 @@ class IVtkTools_ShapeDataSource;
|
||||
class IVtkTools_EXPORT IVtkTools_ShapeObject : public vtkDataObject
|
||||
{
|
||||
public:
|
||||
vtkTypeMacro (IVtkTools_ShapeObject, vtkObject);
|
||||
vtkTypeMacro (IVtkTools_ShapeObject, vtkObject)
|
||||
|
||||
static IVtkTools_ShapeObject* New();
|
||||
|
||||
|
@@ -30,7 +30,7 @@
|
||||
//! before the user starts to select interactively, in order for the OCCT selection
|
||||
//! algorithm to prepare its internal selection data.
|
||||
|
||||
vtkStandardNewMacro(IVtkTools_ShapePicker);
|
||||
vtkStandardNewMacro(IVtkTools_ShapePicker)
|
||||
|
||||
//============================================================================
|
||||
// Method: IVtkTools_ShapePicker
|
||||
|
@@ -29,7 +29,8 @@ class vtkActorCollection;
|
||||
class IVtkTools_EXPORT IVtkTools_ShapePicker : public vtkAbstractPropPicker
|
||||
{
|
||||
public:
|
||||
vtkTypeMacro(IVtkTools_ShapePicker, vtkAbstractPropPicker);
|
||||
vtkTypeMacro(IVtkTools_ShapePicker, vtkAbstractPropPicker)
|
||||
|
||||
static IVtkTools_ShapePicker* New();
|
||||
|
||||
//! Pick entities in the given point or area.
|
||||
|
@@ -23,7 +23,7 @@
|
||||
#include <vtkIdTypeArray.h>
|
||||
|
||||
|
||||
vtkStandardNewMacro(IVtkTools_SubPolyDataFilter);
|
||||
vtkStandardNewMacro(IVtkTools_SubPolyDataFilter)
|
||||
|
||||
//================================================================
|
||||
// Function : Constructor
|
||||
|
@@ -26,7 +26,8 @@
|
||||
class IVtkTools_EXPORT IVtkTools_SubPolyDataFilter : public vtkPolyDataAlgorithm
|
||||
{
|
||||
public:
|
||||
vtkTypeMacro(IVtkTools_SubPolyDataFilter,vtkPolyDataAlgorithm);
|
||||
vtkTypeMacro(IVtkTools_SubPolyDataFilter,vtkPolyDataAlgorithm)
|
||||
|
||||
static IVtkTools_SubPolyDataFilter *New();
|
||||
void PrintSelf (std::ostream& theOs, vtkIndent theIndent);
|
||||
|
||||
|
@@ -27,8 +27,8 @@ IMPLEMENT_STANDARD_RTTIEXT(IVtkVTK_View,IVtk_IView)
|
||||
// Since VTK 6 the factory methods require "auto-initialization" depending on
|
||||
// what modules are enabled at VTK configure time.
|
||||
// Some defines are needed in order to make the factories work properly.
|
||||
VTK_MODULE_INIT(vtkRenderingOpenGL);
|
||||
VTK_MODULE_INIT(vtkInteractionStyle);
|
||||
VTK_MODULE_INIT(vtkRenderingOpenGL)
|
||||
VTK_MODULE_INIT(vtkInteractionStyle)
|
||||
|
||||
// Handle implementation
|
||||
|
||||
|
@@ -101,7 +101,7 @@ namespace
|
||||
return FIT_UNKNOWN;
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
|
@@ -126,7 +126,8 @@ namespace
|
||||
|| theFormat == Image_PixMap::ImgRGBA
|
||||
|| theFormat == Image_PixMap::ImgBGRA;
|
||||
}
|
||||
}
|
||||
|
||||
} // anonymous namespace
|
||||
|
||||
// =======================================================================
|
||||
// function : Image_Diff
|
||||
|
@@ -32,11 +32,6 @@ extern "C" {
|
||||
#define fstatvfs fstatfs
|
||||
#else
|
||||
#include <sys/statvfs.h>
|
||||
#ifdef __GNU_LIBRARY__
|
||||
int statvfs(const char *, struct statvfs *) __THROW;
|
||||
#else
|
||||
int statvfs(const char *, struct statvfs *);
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
@@ -43,13 +43,6 @@ extern "C" {void *dlerror (void);}
|
||||
|
||||
#include <dlfcn.h>
|
||||
|
||||
#ifdef __GNU_LIBRARY__
|
||||
extern "C" { size_t strlen(const char* s) __THROW; }
|
||||
#else
|
||||
extern "C" { size_t strlen(const char* s); }
|
||||
#endif
|
||||
|
||||
|
||||
#define BAD(X) ((X) == NULL)
|
||||
|
||||
// ----------------------------------------------------------------
|
||||
|
@@ -136,7 +136,7 @@ namespace
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
} // anonymous namespace
|
||||
|
||||
// =======================================================================
|
||||
// function : OpenGl_Text
|
||||
|
@@ -418,7 +418,8 @@ namespace
|
||||
aPrsGrp->SetGroupPrimitivesAspect (aBoundaryAspect);
|
||||
aPrsGrp->AddPrimitiveArray (aSegments);
|
||||
}
|
||||
}
|
||||
|
||||
} // anonymous namespace
|
||||
|
||||
// =======================================================================
|
||||
// function : ExploreSolids
|
||||
|
@@ -357,9 +357,9 @@ static Standard_Boolean FUN_findTOOF(const TopOpeBRepDS_PDataStructure pDS,
|
||||
return ok;
|
||||
}
|
||||
|
||||
Standard_EXPORT Standard_Boolean GLOBAL_btcx = Standard_False;void debtcx(){}
|
||||
Standard_EXPORT Standard_Boolean GLOBAL_btcx = Standard_False;
|
||||
Standard_EXPORT void debtcxmess(Standard_Integer f1,Standard_Integer f2,Standard_Integer il)
|
||||
{cout<<"f1,f2,il : "<<f1<<","<<f2<<","<<il<<endl;cout.flush();debtcx();}
|
||||
{cout<<"f1,f2,il : "<<f1<<","<<f2<<","<<il<<endl;cout.flush();}
|
||||
|
||||
//=======================================================================
|
||||
//function : ProcessLine
|
||||
|
@@ -6461,13 +6461,10 @@ public:
|
||||
const Standard_ShortReal theXShift,
|
||||
const Standard_ShortReal theYShift,
|
||||
const Standard_ShortReal theAngle);
|
||||
DEFINE_STANDARD_RTTI_INLINE(OCC_TextureEnv,Graphic3d_TextureEnv);
|
||||
DEFINE_STANDARD_RTTI_INLINE(OCC_TextureEnv,Graphic3d_TextureEnv)
|
||||
};
|
||||
DEFINE_STANDARD_HANDLE(OCC_TextureEnv, Graphic3d_TextureEnv)
|
||||
|
||||
|
||||
|
||||
|
||||
OCC_TextureEnv::OCC_TextureEnv(const Standard_CString theFileName)
|
||||
: Graphic3d_TextureEnv(theFileName)
|
||||
{
|
||||
|
Reference in New Issue
Block a user