Compilation issue in ComplexQZ.h: 'steps' set but not used
Summary
When compiling git head (d426838d) using a recent clang and -Wall, I get the following errors:
Eigen/src/Eigenvalues/ComplexQZ.h:272:7: error: variable 'steps' set but not used [-Werror,-Wunused-but-set-variable]
272 | int steps = 0;
/Users/russ/tools/eigen-latest/Eigen/src/Eigenvalues/ComplexQZ.h:334:16: error: variable 'steps' set but not used [-Werror,-Wunused-but-set-variable]
334 | unsigned int steps = 0;
The compiler is correct in this case - the variable 'steps' is set but never used in two places. Possible solutions are to remove it, or if it's going to be useful later, add [[maybe_unused]].
Environment
- Operating System : MacOS
- Architecture : Arm64
- Eigen Version : head
- Compiler Version : clang version 21.0.0git
- Compile Flags : -Werror -Wall -std=c++20