mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-05-02 05:04:08 +08:00
Mark simple min, max, abs methods as const
This commit is contained in:
parent
66e1b406b8
commit
2ad3ec46b9
@ -413,7 +413,7 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
Matrix<Type, M, N> abs()
|
||||
Matrix<Type, M, N> abs() const
|
||||
{
|
||||
Matrix<Type, M, N> r;
|
||||
for (size_t i=0; i<M; i++) {
|
||||
@ -424,7 +424,7 @@ public:
|
||||
return r;
|
||||
}
|
||||
|
||||
Type max()
|
||||
Type max() const
|
||||
{
|
||||
Type max_val = (*this)(0,0);
|
||||
for (size_t i=0; i<M; i++) {
|
||||
@ -438,7 +438,7 @@ public:
|
||||
return max_val;
|
||||
}
|
||||
|
||||
Type min()
|
||||
Type min() const
|
||||
{
|
||||
Type min_val = (*this)(0,0);
|
||||
for (size_t i=0; i<M; i++) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user