MantisBT
Mantis Bug Tracker Workflow

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0030609Open CASCADE[OCCT] OCCT:Codingpublic2019-03-27 10:222019-10-17 14:23
Reportertizmaylo 
Assigned Tobugmaster 
PrioritynormalSeverityminor 
StatusreviewedResolutionopen 
PlatformOSOS Version
Product Version[OCCT] 7.4.0 
Target Version[OCCT] 7.5.0*Fixed in Version 
Summary0030609: Coding - eliminate warnings issued by gcc 8.1.0
DescriptionA bunch of warnings are issued by the latest g++ version 8.1.0. The warning log is attached (named "mingw_build.warnings").

\occt_mingw64\src\OSD\OSD_Parallel.cxx: In function 'bool {anonymous}::isWow64()':
\occt_mingw64\src\OSD\OSD_Parallel.cxx:45:76: warning: cast between incompatible function types from 
'FARPROC' {aka 'long long int (*)()'} to 'LPFN_ISWOW64PROCESS' {aka 'int (*)(void*, int*)'} [-Wcast-function-type]
       
: (LPFN_ISWOW64PROCESS)GetProcAddress(aKern32Module, "IsWow64Process");
                                                                            ^
\occt_mingw64\src\OSD\OSD_Parallel.cxx: In static member function 'static Standard_Integer OSD_Parallel::NbLogicalProcessors()':

\occt_mingw64\src\OSD\OSD_Parallel.cxx:224:85: warning: cast between incompatible function types from 
'FARPROC' {aka 'long long int (*)()'} to 'LPFN_GSI' {aka 'int (*)(_SYSTEM_INFO*)'} [-Wcast-function-type]
     
LPFN_GSI aFuncSysInfo = (LPFN_GSI )GetProcAddress(aKern32, "GetNativeSystemInfo");
                                                                                     ^
\occt_mingw64\src\OSD\OSD_signal.cxx: In function 'void SIGWntHandler(int, int)':
\occt_mingw64\src\OSD\OSD_signal.cxx:284:43: warning: cast between incompatible function types from 'void 
(*)(int, int)' to 'void (*)(int)' [-Wcast-function-type]
       if ( signal( signum , (void(*)(int))SIGWntHandler ) == SIG_ERR )
                                           ^~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_signal.cxx:312:42: warning: cast between incompatible function types from 'void 
(*)(int, int)' to 'void (*)(int)' [-Wcast-function-type]
       if ( signal( signum, (void(*)(int))SIGWntHandler ) == SIG_ERR )
                                          ^~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_signal.cxx:317:42: warning: cast between incompatible function types from 'void 
(*)(int, int)' to 'void (*)(int)' [-Wcast-function-type]
       if ( signal( signum, (void(*)(int))SIGWntHandler ) == SIG_ERR )
                                          ^~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_signal.cxx: In static member function 'static void OSD::SetSignal(Standard_Boolean)':

\occt_mingw64\src\OSD\OSD_signal.cxx:399:38: warning: cast between incompatible function types from 'void 
(*)(int, int)' to 'void (*)(int)' [-Wcast-function-type]
   if (signal (SIGSEGV, (void(*)(int))SIGWntHandler) == SIG_ERR)
                                      ^~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_signal.cxx:401:38: warning: cast between incompatible function types from 'void 
(*)(int, int)' to 'void (*)(int)' [-Wcast-function-type]
   if (signal (SIGFPE,  (void(*)(int))SIGWntHandler) == SIG_ERR)
                                      ^~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_signal.cxx:403:38: warning: cast between incompatible function types from 'void 
(*)(int, int)' to 'void (*)(int)' [-Wcast-function-type]
   if (signal (SIGILL,  (void(*)(int))SIGWntHandler) == SIG_ERR)
                                      ^~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_SharedLibrary.cxx: In member function 'int (* OSD_SharedLibrary::DlSymb(Standard_CString) 
const)(...)':
\occt_mingw64\src\OSD\OSD_SharedLibrary.cxx:269:83: warning: cast between incompatible function types 
from 'FARPROC' {aka 'long long int (*)()'} to 'OSD_Function' {aka 'int (*)(...)'} [-Wcast-function-type]
  
OSD_Function func = ( OSD_Function )GetProcAddress (  ( HMODULE )myHandle, Name  );
                                                                                   ^
\occt_mingw64\src\OSD\OSD_WNT.cxx: In function 'BOOL MoveDirectory(const wchar_t*, const wchar_t*, DWORD&)':

\occt_mingw64\src\OSD\OSD_WNT.cxx:702:46: warning: division 'sizeof (const wchar_t*) / sizeof (const 
wchar_t)' does not compute the number of array elements [-Wsizeof-pointer-div]
     StringCchLengthW (oldDir, sizeof(oldDir) / sizeof(oldDir[0]), &anOldDirLength);
                               ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:619:43: note: first 'sizeof' operand was declared here
 static BOOL MoveDirectory (const wchar_t* oldDir, const wchar_t* newDir, DWORD& theRecurseLevel)
                            
~~~~~~~~~~~~~~~^~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:706:44: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
       StringCchCopyW (pName, sizeof(pName) / sizeof(pName[0]), oldDir);
                              ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:694:12: note: first 'sizeof' operand was declared here
   wchar_t* pName = NULL;
            ^~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:719:50: warning: division 'sizeof (const wchar_t*) / sizeof (const 
wchar_t)' does not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchLengthW (oldDir, sizeof(oldDir) / sizeof(oldDir[0]), &anOldDirLength2);
                                   ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:619:43: note: first 'sizeof' operand was declared here
 static BOOL MoveDirectory (const wchar_t* oldDir, const wchar_t* newDir, DWORD& theRecurseLevel)
                            
~~~~~~~~~~~~~~~^~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:720:50: warning: division 'sizeof (const wchar_t*) / sizeof (const 
wchar_t)' does not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchLengthW (newDir, sizeof(newDir) / sizeof(newDir[0]), &aNewDirLength);
                                   ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:619:66: note: first 'sizeof' operand was declared here
 static BOOL MoveDirectory (const wchar_t* oldDir, const wchar_t* newDir, DWORD& theRecurseLevel)
                                                   
~~~~~~~~~~~~~~~^~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:728:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCopyW (pFullNameSrc, sizeof(pFullNameSrc) / sizeof(pFullNameSrc[0]), oldDir);
                                       ~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:695:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameSrc = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:729:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCatW  (pFullNameSrc, sizeof(pFullNameSrc) / sizeof(pFullNameSrc[0]), L"/");
                                       
~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:695:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameSrc = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:730:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCatW  (pFullNameSrc, sizeof(pFullNameSrc) / sizeof(pFullNameSrc[0]), pFD->cFileName);
                                       
~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:695:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameSrc = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:732:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCopyW (pFullNameDst, sizeof(pFullNameDst) / sizeof(pFullNameDst[0]), newDir);
                                       ~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:696:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameDst = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:733:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCatW  (pFullNameDst, sizeof(pFullNameDst) / sizeof(pFullNameDst[0]), L"/");
                                       
~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:696:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameDst = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:734:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCatW  (pFullNameDst, sizeof(pFullNameDst) / sizeof(pFullNameDst[0]), pFD->cFileName);
                                       
~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:696:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameDst = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx: In function 'BOOL CopyDirectory(const wchar_t*, const wchar_t*)':

\occt_mingw64\src\OSD\OSD_WNT.cxx:856:46: warning: division 'sizeof (const wchar_t*) / sizeof (const 
wchar_t)' does not compute the number of array elements [-Wsizeof-pointer-div]
     StringCchLengthW (dirSrc, sizeof(dirSrc) / sizeof(dirSrc[0]), &aDirSrcLength);
                               ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:844:36: note: first 'sizeof' operand was declared here
 BOOL CopyDirectory (const wchar_t* dirSrc, const wchar_t* dirDst)
                     ~~~~~~~~~~~~~~~^~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:860:43: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
       StringCchCopyW(pName, sizeof(pName) / sizeof(pName[0]), dirSrc);
                             ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:847:12: note: first 'sizeof' operand was declared here
   wchar_t* pName = NULL;
            ^~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:861:43: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
       StringCchCatW (pName, sizeof(pName) / sizeof(pName[0]), WILD_CARD);
                             ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:847:12: note: first 'sizeof' operand was declared here
   wchar_t* pName = NULL;
            ^~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:874:50: warning: division 'sizeof (const wchar_t*) / sizeof (const 
wchar_t)' does not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchLengthW (dirSrc, sizeof(dirSrc) / sizeof(dirSrc[0]), &aDirSrcLength2);
                                   ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:844:36: note: first 'sizeof' operand was declared here
 BOOL CopyDirectory (const wchar_t* dirSrc, const wchar_t* dirDst)
                     ~~~~~~~~~~~~~~~^~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:875:50: warning: division 'sizeof (const wchar_t*) / sizeof (const 
wchar_t)' does not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchLengthW (dirDst, sizeof(dirDst) / sizeof(dirDst[0]), &aDirDstLength);
                                   ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:844:59: note: first 'sizeof' operand was declared here
 BOOL CopyDirectory (const wchar_t* dirSrc, const wchar_t* dirDst)
                                            ~~~~~~~~~~~~~~~^~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:883:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCopyW (pFullNameSrc, sizeof(pFullNameSrc) / sizeof(pFullNameSrc[0]), dirSrc);
                                       ~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:848:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameSrc = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:884:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCatW  (pFullNameSrc, sizeof(pFullNameSrc) / sizeof(pFullNameSrc[0]), L"/");
                                       
~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:848:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameSrc = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:885:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCatW  (pFullNameSrc, sizeof(pFullNameSrc) / sizeof(pFullNameSrc[0]), pFD->cFileName);
                                       
~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:848:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameSrc = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:887:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCopyW (pFullNameDst, sizeof(pFullNameDst) / sizeof(pFullNameDst[0]), dirDst);
                                       ~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:849:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameDst = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:888:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCatW  (pFullNameDst, sizeof(pFullNameDst) / sizeof(pFullNameDst[0]), L"/");
                                       
~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:849:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameDst = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:889:60: warning: division 'sizeof (wchar_t*) / sizeof (wchar_t)' does 
not compute the number of array elements [-Wsizeof-pointer-div]
         StringCchCatW  (pFullNameDst, sizeof(pFullNameDst) / sizeof(pFullNameDst[0]), pFD->cFileName);
                                       
~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OSD\OSD_WNT.cxx:849:12: note: first 'sizeof' operand was declared here
   wchar_t* pFullNameDst = NULL;
            ^~~~~~~~~~~~
\occt_mingw64\src\Plugin\Plugin.cxx: In static member function 'static opencascade::handle<Standard_Transient> 
Plugin::Load(const Standard_GUID&, Standard_Boolean)':
\occt_mingw64\src\Plugin\Plugin.cxx:97:56: warning: cast between incompatible function types from 'OSD_Function' 
{aka 'int (*)(...)'} to 'Standard_Transient* (*)(const Standard_GUID&)' [-Wcast-function-type]
   fp = (Standard_Transient* (*)(const Standard_GUID&)) f;
                                                        ^
\occt_mingw64\src\Message\Message_MsgFile.cxx: In static member function 'static Standard_Boolean Message_MsgFile::LoadFile(Standard_CString)':

\occt_mingw64\src\Message\Message_MsgFile.cxx:260:85: warning: type qualifiers ignored on cast result 
type [-Wignored-qualifiers]
         reinterpret_cast<const Standard_ExtCharacter* const>(&anMsgBuffer[aFileSize]);
                                                                                     ^
\occt_mingw64\src\Draw\Draw.cxx: In function 'void Draw_Appli(HINSTANCE, HINSTANCE, int, int, wchar_t**, 
FDraw_InitAppli)':
\occt_mingw64\src\Draw\Draw.cxx:281:102: warning: cast between incompatible function types from 'FARPROC' 
{aka 'long long int (*)()'} to 'SetDllDirectoryW_t' {aka 'int (*)(const wchar_t*)'} [-Wcast-function-type]
                              
? (SetDllDirectoryW_t )GetProcAddress (aKern32Module, "SetDllDirectoryW") : NULL;
                                                                                                      
^
\occt_mingw64\src\Draw\Draw.cxx: In static member function 'static void Draw::Load(Draw_Interpretor&, 
const TCollection_AsciiString&, const TCollection_AsciiString&, TCollection_AsciiString&, 
TCollection_AsciiString&, Standard_Boolean)':
\occt_mingw64\src\Draw\Draw.cxx:728:38: warning: cast between incompatible function types from 'OSD_Function' 
{aka 'int (*)(...)'} to 'void (*)(Draw_Interpretor&)' [-Wcast-function-type]
   fp = (void (*)(Draw_Interpretor&)) f;
                                      ^
\occt_mingw64\src\Draw\Draw_Window.cxx: In function 'Standard_Boolean Init_Appli(HINSTANCE, HINSTANCE, 
int, HWND__*&)':
\occt_mingw64\src\Draw\Draw_Window.cxx:2032:53: warning: cast between incompatible function types from 
'DWORD (*)()' {aka 'long unsigned int (*)()'} to 'LPTHREAD_START_ROUTINE' {aka 'long unsigned int (*)(void*)'} 
[-Wcast-function-type]
                            (LPTHREAD_START_ROUTINE) tkLoop, // thread function
                                                     ^~~~~~
\occt_mingw64\src\Draw\Draw_Window.cxx: In function 'DWORD tkLoop()':
\occt_mingw64\src\Draw\Draw_Window.cxx:2312:12: warning: catching polymorphic type 'class Standard_Failure' 
by value [-Wcatch-value=]
     catch (Standard_Failure)
            ^~~~~~~~~~~~~~~~
\occt_mingw64\src\Draw\Draw_Window.cxx: In function 'void Run_Appli(HWND)':
\occt_mingw64\src\Draw\Draw_Window.cxx:2394:53: warning: cast between incompatible function types from 
'DWORD (*)()' {aka 'long unsigned int (*)()'} to 'LPTHREAD_START_ROUTINE' {aka 'long unsigned int (*)(void*)'} 
[-Wcast-function-type]
                            (LPTHREAD_START_ROUTINE) readStdinThreadFunc, // thread function
                                                     ^~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\OpenGl\OpenGl_Window.cxx: In constructor 'OpenGl_Window::OpenGl_Window(const opencascade::handle<OpenGl_GraphicDriver>&, 
const opencascade::handle<Aspect_Window>&, Aspect_RenderingContext, const opencascade::handle<OpenGl_Caps>&, 
const opencascade::handle<OpenGl_Context>&)':
\occt_mingw64\src\OpenGl\OpenGl_Window.cxx:341:129: warning: cast between incompatible function types 
from 'PROC' {aka 'long long int (*)()'} to 'wglGetExtensionsStringARB_t' {aka 'const char* (*)(HDC__*)'} 
[-Wcast-function-type]
       wglGetExtensionsStringARB_t aGetExtensions = (wglGetExtensionsStringARB_t  )wglGetProcAddress 
("wglGetExtensionsStringARB");
                                                                                                                                 
^
\occt_mingw64\src\OpenGl\OpenGl_Window.cxx:345:101: warning: cast between incompatible function types 
from 'PROC' {aka 'long long int (*)()'} to 'wglChoosePixelFormatARB_t' {aka 'int (*)(HDC__*, const int*, 
const float*, unsigned int, int*, unsigned int*)'} [-Wcast-function-type]
         aChoosePixProc = (wglChoosePixelFormatARB_t    )wglGetProcAddress ("wglChoosePixelFormatARB");
                                                                                                     
^
\occt_mingw64\src\OpenGl\OpenGl_Window.cxx:349:104: warning: cast between incompatible function types 
from 'PROC' {aka 'long long int (*)()'} to 'wglCreateContextAttribsARB_t' {aka 'HGLRC__* (*)(HDC__*, 
HGLRC__*, const int*)'} [-Wcast-function-type]
         aCreateCtxProc = (wglCreateContextAttribsARB_t )wglGetProcAddress ("wglCreateContextAttribsARB");
                                                                                                        
^
\occt_mingw64\src\D3DHost\D3DHost_View.cxx: In member function 'bool D3DHost_View::d3dInitLib()':
\occt_mingw64\src\D3DHost\D3DHost_View.cxx:146:114: warning: cast between incompatible function types 
from 'FARPROC' {aka 'long long int (*)()'} to 'Direct3DCreate9Ex_t' {aka 'long int (*)(unsigned int, 
IDirect3D9Ex**)'} [-Wcast-function-type]
       Direct3DCreate9Ex_t Direct3DCreate9ExProc = (Direct3DCreate9Ex_t )GetProcAddress (aLib, "Direct3DCreate9Ex");
                                                                                                                  
^
\occt_mingw64\src\BiTgte\BiTgte_Blend.cxx: In member function 'BiTgte_ContactType BiTgte_Blend::ContactType(Standard_Integer) 
const':
\occt_mingw64\src\BiTgte\BiTgte_Blend.cxx:1198:5: warning: this statement may fall through [-Wimplicit-fallthrough=]
     
switch (Type2) {
     ^~~~~~
\occt_mingw64\src\BiTgte\BiTgte_Blend.cxx:1206:3: note: here
   case TopAbs_EDGE:
   ^~~~
\occt_mingw64\src\BiTgte\BiTgte_Blend.cxx:1207:5: warning: this statement may fall through [-Wimplicit-fallthrough=]
     
switch (Type2) {
     ^~~~~~
\occt_mingw64\src\BiTgte\BiTgte_Blend.cxx:1214:3: note: here
   case TopAbs_FACE:
   ^~~~
\occt_mingw64\src\SWDRAW\SWDRAW_ShapeAnalysis.cxx: In function 'Standard_Integer MyVISEDG(Draw_Interpretor&, 
Standard_Integer, const char**)':
\occt_mingw64\src\SWDRAW\SWDRAW_ShapeAnalysis.cxx:865:11: warning: 'char* strncat(char*, const char*, 
size_t)' output truncated before terminating nul copying as many bytes from a string as its length [-Wstringop-truncation]
    
strncat(name,num,strlen(num));
    ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
\occt_mingw64\src\SWDRAW\SWDRAW_ShapeAnalysis.cxx:880:11: warning: 'char* strncat(char*, const char*, 
size_t)' output truncated before terminating nul copying as many bytes from a string as its length [-Wstringop-truncation]
    
strncat(name,num,strlen(num));
    ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
Building time: 00:21:24 
Steps To ReproduceCompile OCCT with the g++ version 8.1.0 and redirect standard error to some file.
TagsNo tags attached.
Test case number
Attached Files? file icon mingw_build.warnings (130,422 bytes) 2019-03-27 10:22
log file icon build-mingw64-8.3.0.log (21,184 bytes) 2019-05-06 12:44

- Relationships
parent of 0030611verifiedkgv Coding Rules - eliminate GCC compiler warnings -Wcatch-value 
parent of 0030684verifiedbugmaster Coding Rules - eliminate GCC compiler warnings -Wformat-overflow and -Wcatch-value 
related to 0031004newkgv Coding - eliminate warnings issued by gcc 9.1.0 
related to 0031060reviewedbugmaster Configuration - Support building with CLang compiler under VS 2019 
child of 0027197closedabv Configuration - fix compilation issues when using mingw 

-  Notes
(0087512)
git (administrator)
2019-09-25 16:33

Branch CR30609 has been created by tizmaylo.

SHA-1: ea5d00cca06213a44560ba48c20d464f1d0c109d


Detailed log of new commits:

Author: tiv
Date: Wed Sep 25 16:32:34 2019 +0300

    0030609: Coding - eliminate warnings issued by gcc 8.1.0
    
    Warnings issued by gcc 8.1.0 are eliminated.
    Some macros necessary for compiler detection and gcc warning's suppression are added to Standard_Macro.hxx header file.
(0087552)
git (administrator)
2019-09-26 17:45

Branch CR30609 has been updated by tizmaylo.

SHA-1: 6ee64588f558cbd2657e2806a5a5df8629b6ffa5


Detailed log of new commits:

Author: tiv
Date: Thu Sep 26 17:24:23 2019 +0300

    New function OSD_FunctionCast() is introduced to explicitly mark places where the conversion from the pointer to one function type to the pointer to another function type takes place and to suppress gcc warning "-Wcast-function-type".

(0087553)
git (administrator)
2019-09-26 17:45

Branch CR30609_1 has been created by tizmaylo.

SHA-1: a16469a2ed72fd4d2dd79047379944d79d414051


Detailed log of new commits:

Author: tiv
Date: Thu Sep 26 17:43:07 2019 +0300

    0030609: Coding - eliminate warnings issued by gcc 8.1.0
    
    Warnings issued by gcc 8.1.0 are eliminated.
    Some macros necessary for compiler detection and gcc warning's suppression are added to Standard_Macro.hxx header file.
    New function OSD_FunctionCast() is introduced to explicitly mark places where the conversion from the pointer to one function type to the pointer to another function type takes place and to suppress gcc warning "-Wcast-function-type".
(0087567)
tizmaylo (developer)
2019-09-27 12:08

Patch is ready for review: http://vm-jenkins-test-12.nnov.opencascade.com:8080/view/CR30609-master-TIV/view/ALL/ [^]

Main OCCT branch: CR30609
OCCT branch with squashed commits: CR30609_1
(0088079)
abv (manager)
2019-10-14 09:21

The patch contains excessive changes, for instance, it defines 11 new preprocessor macros OCCT_COMPILER*, only one of which is used (in the same file!). Please avoid redundant and unnecessary things.
(0088141)
kgv (developer)
2019-10-15 20:17

Please take into account Andrey remarks.
(0088164)
git (administrator)
2019-10-16 12:03

Branch CR30609 has been updated forcibly by tizmaylo.

SHA-1: cbf97ac7520ef572ffbb9c79f4725e76cf785229
(0088165)
git (administrator)
2019-10-16 12:03

Branch CR30609_1 has been updated forcibly by tizmaylo.

SHA-1: e4cd18cd91e4bad31ddc876f4b375243561596c6
(0088167)
git (administrator)
2019-10-16 12:16

Branch CR30609 has been updated forcibly by tizmaylo.

SHA-1: 7ea2ec09e3160176077cfd20ed92e27d3b239ac9
(0088168)
git (administrator)
2019-10-16 12:16

Branch CR30609_1 has been updated forcibly by tizmaylo.

SHA-1: 422ae088dea8e58713078cacac62e4a897413aba
(0088174)
tizmaylo (developer)
2019-10-16 14:28
edited on: 2019-10-16 14:30

Patch is ready for review: http://vm-jenkins-test-12.nnov.opencascade.com:8080/view/CR30609-master-TIV/view/ALL/ [^]

Main OCCT branch: CR30609
OCCT branch with squashed commits: CR30609_1

Attention: both branches have been forcibly updated.

(0088190)
kgv (developer)
2019-10-16 17:50

+      std::ostringstream aNameStream;
+      aNameStream << 'w' << iwire;
+      const std::string aName = aNameStream.str();
+      DBRep::Set (aName.c_str(), S.Value());

Please replace with TCollection_AsciiString.

author	tiv <tiv@opencascade.com>	
Warnings issued by gcc 8.1.0 are eliminated.

Please correct commit description.
(0088200)
git (administrator)
2019-10-16 20:52

Branch CR30609 has been updated by tizmaylo.

SHA-1: 1996f7f61e23fd01932c2da41a2cfd1597d41d68


Detailed log of new commits:

Author: tiv
Date: Wed Oct 16 20:45:45 2019 +0300

(0088201)
git (administrator)
2019-10-16 20:53

Branch CR30609_1 has been updated forcibly by tizmaylo.

SHA-1: a4e305469473f864e57d66dc5740b1af2db995b9
(0088219)
git (administrator)
2019-10-17 10:21

Branch CR30609_2 has been created by abv.

SHA-1: 79727c877084ed67c9fb7873ad472e446e9476de


Detailed log of new commits:

Author: tiv
Date: Wed Oct 16 20:47:30 2019 +0300

    0030609: Coding - eliminate warnings issued by gcc 8.1.0
    
    Warnings issued by gcc 8.1.0 are eliminated.
    New function OSD_FunctionCast() is introduced to explicitly mark places where the conversion from the pointer to one function type to the pointer to another function type takes place and to suppress gcc warning "-Wcast-function-type" (introduced in gcc 8.1.0).
(0088220)
abv (manager)
2019-10-17 10:23

I have removed the function MyVISEDG in SWDRAW_ShapeAnalysis.cxx as it does not seem to do anything useful and relevant DRAW command is never used in tests. Please review branch CR30609_2.

- Issue History
Date Modified Username Field Change
2019-03-27 10:22 tizmaylo New Issue
2019-03-27 10:22 tizmaylo Assigned To => kgv
2019-03-27 10:22 tizmaylo File Added: mingw_build.warnings
2019-03-27 14:14 kgv Relationship added child of 0027197
2019-03-27 14:14 kgv Summary Eliminate warnings issued by the latest g++ version 8.1.0 => Coding - eliminate warnings issued by gcc 8.1.0
2019-03-27 17:52 kgv Relationship added parent of 0030611
2019-05-01 22:41 kgv Relationship added parent of 0030684
2019-05-06 12:44 kgv File Added: build-mingw64-8.3.0.log
2019-05-06 12:47 kgv Description Updated View Revisions
2019-09-04 17:35 kgv Assigned To kgv => tizmaylo
2019-09-04 17:35 kgv Status new => assigned
2019-09-04 17:35 kgv Product Version => 7.4.0
2019-09-25 16:33 git Note Added: 0087512
2019-09-25 18:29 kgv Target Version 7.4.0 => 7.5.0*
2019-09-26 11:47 tizmaylo Relationship added related to 0031004
2019-09-26 17:45 git Note Added: 0087552
2019-09-26 17:45 git Note Added: 0087553
2019-09-27 12:08 tizmaylo Note Added: 0087567
2019-09-27 12:09 tizmaylo Assigned To tizmaylo => kgv
2019-09-27 12:09 tizmaylo Status assigned => resolved
2019-09-27 12:09 tizmaylo Steps to Reproduce Updated View Revisions
2019-10-14 09:21 abv Note Added: 0088079
2019-10-15 20:17 kgv Note Added: 0088141
2019-10-15 20:17 kgv Assigned To kgv => tizmaylo
2019-10-15 20:17 kgv Status resolved => assigned
2019-10-16 12:03 git Note Added: 0088164
2019-10-16 12:03 git Note Added: 0088165
2019-10-16 12:16 git Note Added: 0088167
2019-10-16 12:16 git Note Added: 0088168
2019-10-16 14:28 tizmaylo Note Added: 0088174
2019-10-16 14:28 tizmaylo Note Edited: 0088174 View Revisions
2019-10-16 14:29 tizmaylo Assigned To tizmaylo => kgv
2019-10-16 14:29 tizmaylo Status assigned => resolved
2019-10-16 14:30 tizmaylo Note Edited: 0088174 View Revisions
2019-10-16 17:50 kgv Note Added: 0088190
2019-10-16 17:50 kgv Assigned To kgv => tizmaylo
2019-10-16 17:50 kgv Status resolved => assigned
2019-10-16 20:52 git Note Added: 0088200
2019-10-16 20:53 git Note Added: 0088201
2019-10-17 10:21 git Note Added: 0088219
2019-10-17 10:23 abv Note Added: 0088220
2019-10-17 10:23 abv Assigned To tizmaylo => kgv
2019-10-17 10:23 abv Status assigned => resolved
2019-10-17 10:44 kgv Assigned To kgv => bugmaster
2019-10-17 10:44 kgv Status resolved => reviewed
2019-10-17 14:23 abv Relationship added related to 0031060


Copyright © 2000 - 2019 MantisBT Team
Powered by Mantis Bugtracker