mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-16 04:45:24 +03:00
Removing inline from constrin and constrainf.
These functions are used elsewhere and the inline declaration can cause the compiler to make them static and unavailable outside of this file. Unless these functions are defined in a .h file, they cannot be inlined.
This commit is contained in:
parent
3f524297d1
commit
61392c5afc
1 changed files with 2 additions and 2 deletions
|
@ -111,7 +111,7 @@ int32_t applyDeadband(int32_t value, int32_t deadband)
|
|||
return value;
|
||||
}
|
||||
|
||||
inline int constrain(int amt, int low, int high)
|
||||
int constrain(int amt, int low, int high)
|
||||
{
|
||||
if (amt < low)
|
||||
return low;
|
||||
|
@ -121,7 +121,7 @@ inline int constrain(int amt, int low, int high)
|
|||
return amt;
|
||||
}
|
||||
|
||||
inline float constrainf(float amt, float low, float high)
|
||||
float constrainf(float amt, float low, float high)
|
||||
{
|
||||
if (amt < low)
|
||||
return low;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue