Archived issue #0026872
Coding - pointless instantiations of local variables in BinTools
Description
Several methods of classes in BinTools package start with declaration of local variable "Standard_SStream aMsg" which is used only in error handling (i.e. never in normal situations). This does not make any sense and causes execution of unnecessary code at every call. These vars should be instantiated locally only in places where they are used.
Steps to reproduce
N/A
Public activity
5 archived notes
Participants are labeled by their role within this record.
Branch [archived branch] has been created by Author.
[revision removed]
Detailed log of new commits:
Author: Author
Date: Sun Nov 15 09:11:52 2015 +0300
0026872: Coding - pointless instantiations of local variables in BinTools
Instantiations of local stringstream variables used in error handling moved from upper function scope to places where they are actually needed
[revision removed]
Detailed log of new commits:
Author: Author
Date: Sun Nov 15 09:11:52 2015 +0300
0026872: Coding - pointless instantiations of local variables in BinTools
Instantiations of local stringstream variables used in error handling moved from upper function scope to places where they are actually needed
Fix pushed to CR26872, please review
Please check compilation, testing is not needed.
Dear Commenter 1,
Branch CR26872 from occt git-repository (and master from products git-repository) was compiled on Linux, MacOS and Windows platforms.
[revision removed]
Number of compiler warnings:
occt component:
Linux: 0 (0 on master)
Windows: 0 (0 on master)
MacOS: 128 (129 on master)
products component:
Linux: 39 (39 on master)
Windows: 0 (0 on master)
Branch CR26872 from occt git-repository (and master from products git-repository) was compiled on Linux, MacOS and Windows platforms.
[revision removed]
Number of compiler warnings:
occt component:
Linux: 0 (0 on master)
Windows: 0 (0 on master)
MacOS: 128 (129 on master)
products component:
Linux: 39 (39 on master)
Windows: 0 (0 on master)
Branch [archived branch] has been deleted by Commenter 3.
[revision removed]
[revision removed]