mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-20 00:51:42 +00:00
Finish clang-tidy cleanups (#3003)
* Add .clang-tidy configuration. * A separate .clang-tidy is used for hal includes to suppress modernize-use-using (as these are C headers). * Add NOLINT where necessary for a clean run. * Add clang-tidy job to lint-format workflow. This workflow is now only run on PRs. To reduce runtime, clang-tidy is only run on files changed in the PR. Two wpilibc changes; both are unlikely to break user code: * BuiltInAccelerometer: Make SetRange() final * Counter: Make SetMaxPeriod() final After these cleanups, the only file that does not run cleanly is cscore_raw_cv.h due to it not being standalone.
This commit is contained in:
@@ -117,7 +117,7 @@ Java_edu_wpi_first_math_WPIMathJNI_pow
|
||||
|
||||
Eigen::Map<
|
||||
Eigen::Matrix<double, Eigen::Dynamic, Eigen::Dynamic, Eigen::RowMajor>>
|
||||
Amat{arrayBody, rows, rows};
|
||||
Amat{arrayBody, rows, rows}; // NOLINT
|
||||
Eigen::Matrix<double, Eigen::Dynamic, Eigen::Dynamic, Eigen::RowMajor> Apow =
|
||||
Amat.pow(exponent);
|
||||
|
||||
@@ -146,7 +146,7 @@ Java_edu_wpi_first_math_WPIMathJNI_isStabilizable
|
||||
Eigen::Matrix<double, Eigen::Dynamic, Eigen::Dynamic, Eigen::RowMajor>>
|
||||
B{nativeB, states, inputs};
|
||||
|
||||
bool isStabilizable = check_stabilizable(A, B);
|
||||
bool isStabilizable = check_stabilizable(A, B); // NOLINT
|
||||
|
||||
env->ReleaseDoubleArrayElements(aSrc, nativeA, 0);
|
||||
env->ReleaseDoubleArrayElements(bSrc, nativeB, 0);
|
||||
|
||||
@@ -47,7 +47,7 @@ ChassisSpeeds MecanumDriveKinematics::ToChassisSpeeds(
|
||||
Eigen::Vector3d chassisSpeedsVector =
|
||||
m_forwardKinematics.solve(wheelSpeedsMatrix);
|
||||
|
||||
return {units::meters_per_second_t{chassisSpeedsVector(0)},
|
||||
return {units::meters_per_second_t{chassisSpeedsVector(0)}, // NOLINT
|
||||
units::meters_per_second_t{chassisSpeedsVector(1)},
|
||||
units::radians_per_second_t{chassisSpeedsVector(2)}};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user