Archived issue #0027066
BRepFeat_MakeCylindricalHole::Perform() hides overloaded virtual function
Description
CLang compiler reports two warnings in BRepFeat_MakeCylindricalHole (see #0025076):
[user path removed]/occt/src/BRepFeat/BRepFeat_MakeCylindricalHole.hxx:58:24: warning:
'BRepFeat_MakeCylindricalHole::Perform' hides overloaded virtual function
[-Woverloaded-virtual]
Standard_EXPORT void Perform (const Standard_Real Radius);
^
[user path removed]/occt/src/BOPAlgo/BOPAlgo_BOP.hxx:62:32: note: hidden overloaded
virtual function 'BOPAlgo_BOP::Perform' declared here: different number of
parameters (0 vs 1)
Standard_EXPORT virtual void Perform() Standard_OVERRIDE;
^
[user path removed]/occt/src/BRepFeat/BRepFeat_MakeCylindricalHole.hxx:65:24: warning:
'BRepFeat_MakeCylindricalHole::Perform' hides overloaded virtual function
[-Woverloaded-virtual]
Standard_EXPORT void Perform (const Standard_Real Radius, const Standa...
^
[user path removed]/occt/src/BOPAlgo/BOPAlgo_BOP.hxx:62:32: note: hidden overloaded
virtual function 'BOPAlgo_BOP::Perform' declared here: different number of
parameters (0 vs 4)
Standard_EXPORT virtual void Perform() Standard_OVERRIDE;
It is not clear whether hidden method should be redefined on this level. If it does not (which means inherited implementation is OK), we can just import it by "using" directive to silence the warning.
[user path removed]/occt/src/BRepFeat/BRepFeat_MakeCylindricalHole.hxx:58:24: warning:
'BRepFeat_MakeCylindricalHole::Perform' hides overloaded virtual function
[-Woverloaded-virtual]
Standard_EXPORT void Perform (const Standard_Real Radius);
^
[user path removed]/occt/src/BOPAlgo/BOPAlgo_BOP.hxx:62:32: note: hidden overloaded
virtual function 'BOPAlgo_BOP::Perform' declared here: different number of
parameters (0 vs 1)
Standard_EXPORT virtual void Perform() Standard_OVERRIDE;
^
[user path removed]/occt/src/BRepFeat/BRepFeat_MakeCylindricalHole.hxx:65:24: warning:
'BRepFeat_MakeCylindricalHole::Perform' hides overloaded virtual function
[-Woverloaded-virtual]
Standard_EXPORT void Perform (const Standard_Real Radius, const Standa...
^
[user path removed]/occt/src/BOPAlgo/BOPAlgo_BOP.hxx:62:32: note: hidden overloaded
virtual function 'BOPAlgo_BOP::Perform' declared here: different number of
parameters (0 vs 4)
Standard_EXPORT virtual void Perform() Standard_OVERRIDE;
It is not clear whether hidden method should be redefined on this level. If it does not (which means inherited implementation is OK), we can just import it by "using" directive to silence the warning.
Steps to reproduce
Perform() from BOPAlgo_BOP class is now visible on the level of BRepFeat_MakeCylindricalHole
Public activity
9 archived notes
Participants are labeled by their role within this record.
Dear Ilya, please take care of this bug, as it concerns the same class as the bug you are processing #26724.
Branch [archived branch] has been created by Participant.
[revision removed]
Detailed log of new commits:
Author: isn
Date: Mon Jan 11 18:32:41 2016 +0300
0027066: BRepFeat_MakeCylindricalHole::Perform() hides overloaded virtual function
[revision removed]
Detailed log of new commits:
Author: isn
Date: Mon Jan 11 18:32:41 2016 +0300
0027066: BRepFeat_MakeCylindricalHole::Perform() hides overloaded virtual function
Branch [archived branch] has been updated forcibly by Participant.
[revision removed]
[revision removed]
Why did you put 'using' in public section? I think if there is possibility we should hide this declaration in protected section in order to prevent unintended use of this method.
Branch [archived branch] has been updated by Participant.
[revision removed]
Detailed log of new commits:
Author: isn
Date: Wed Jan 13 11:57:10 2016 +0300
move to protected section
[revision removed]
Detailed log of new commits:
Author: isn
Date: Wed Jan 13 11:57:10 2016 +0300
move to protected section
Reviewed.
Dear Commenter 1,
Branch CR27066 from occt git-repository (and master from products git-repository) was compiled on Linux, MacOS and Windows platforms and tested on Release mode.
[revision removed]
Number of compiler warnings:
occt component :
Linux: 0 (0 on master)
Windows: 0 (0 on master)
MacOS : 136 (136 on master)
products component :
Linux: 37 (37 on master)
Windows: 0 (0 on master)
Regressions/Differences/Improvements:
No regressions/differences
Testing cases:
Not needed
Testing on Linux:
occt component :
Total MEMORY difference: 89993586 / 89884726 [+0.12%]
Total CPU difference: 19232.340000000073 / 19263.900000000092 [-0.16%]
products component :
Total MEMORY difference: 25285547 / 25273773 [+0.05%]
Total CPU difference: 8447.780000000017 / 7373.110000000011 [+14.58%]
Testing on Windows:
occt component :
Total MEMORY difference: 57211257 / 57466619 [-0.44%]
Total CPU difference: 18227.82764429891 / 18535.477216399115 [-1.66%]
products component :
Total MEMORY difference: 16923491 / 17032519 [-0.64%]
Total CPU difference: 5931.579222699998 / 5812.004456199969 [+2.06%]
There are no differences in images found by testdiff.
Branch CR27066 from occt git-repository (and master from products git-repository) was compiled on Linux, MacOS and Windows platforms and tested on Release mode.
[revision removed]
Number of compiler warnings:
occt component :
Linux: 0 (0 on master)
Windows: 0 (0 on master)
MacOS : 136 (136 on master)
products component :
Linux: 37 (37 on master)
Windows: 0 (0 on master)
Regressions/Differences/Improvements:
No regressions/differences
Testing cases:
Not needed
Testing on Linux:
occt component :
Total MEMORY difference: 89993586 / 89884726 [+0.12%]
Total CPU difference: 19232.340000000073 / 19263.900000000092 [-0.16%]
products component :
Total MEMORY difference: 25285547 / 25273773 [+0.05%]
Total CPU difference: 8447.780000000017 / 7373.110000000011 [+14.58%]
Testing on Windows:
occt component :
Total MEMORY difference: 57211257 / 57466619 [-0.44%]
Total CPU difference: 18227.82764429891 / 18535.477216399115 [-1.66%]
products component :
Total MEMORY difference: 16923491 / 17032519 [-0.64%]
Total CPU difference: 5931.579222699998 / 5812.004456199969 [+2.06%]
There are no differences in images found by testdiff.
Dear Commenter 1,
Branch CR27066 is TESTED.
Branch CR27066 is TESTED.
Branch [archived branch] has been deleted by Participant.
[revision removed]
[revision removed]
Related records