mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-05-17 05:37:35 +08:00
Fix clang-tidy warnings
This comes from PX4 CI.
This commit is contained in:
@@ -93,8 +93,9 @@ template<typename Integer>
|
||||
Integer wrap(Integer x, Integer low, Integer high) {
|
||||
const auto range = high - low;
|
||||
|
||||
if (x < low)
|
||||
if (x < low) {
|
||||
x += range * ((low - x) / range + 1);
|
||||
}
|
||||
|
||||
return low + (x - low) % range;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user