mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-07-02 02:51:42 +00:00
clang-tidy: bugprone-virtual-near-miss
A few virtual functions are called by constructors or destructors, which is dangerous in C++ (as an overridden virtual impl won't be called, only the one in the current class). Fix by either marking the function final or not calling at all (if possible).
This commit is contained in:
@@ -87,7 +87,7 @@ class ADXRS450_Gyro : public GyroBase {
|
||||
* robot is first turned on while it's sitting at rest before the competition
|
||||
* starts.
|
||||
*/
|
||||
void Calibrate() override;
|
||||
void Calibrate() final;
|
||||
|
||||
/**
|
||||
* Get the SPI port number.
|
||||
|
||||
Reference in New Issue
Block a user