[vtk-developers] new warnings: explicitly assigning a variable to itself
Sean McBride
sean at rogue-research.com
Mon Jan 17 11:21:51 EST 2011
Hi all,
I updated by build of clang on one of our dashboards and now VTK gives
new warnings:
<http://www.cdash.org/CDash/viewBuildError.php?type=1&buildid=826991>
The pattern is always code like:
int tempi;
double tempd;
static char temps[80];
int error;
error = 0; error = error;
tempi = 0; tempi = tempi;
tempd = 0; tempd = tempd;
temps[0] = 0; temps[0] = temps[0];
The warning is:
Charts/vtkPlotPointsTcl.cxx:43:20: warning: explicitly assigning a
variable of type 'int' to itself [-Wself-assign]
error = 0; error = error;
~~~~~ ^ ~~~~~
The purpose of "error = error" escapes me, and yet this pattern is
repeated in many files...
--
____________________________________________________________
Sean McBride, B. Eng sean at rogue-research.com
Rogue Research www.rogue-research.com
Mac Software Developer Montréal, Québec, Canada
More information about the vtk-developers
mailing list