Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AP_Mission: Change the IF statement to a SWITCH statement #26947

Conversation

muramura
Copy link
Contributor

@muramura muramura commented May 1, 2024

Multiple decisions are being made for the same variable value.
In this case, the SWITCH statement is better than the IF statement.

@peterbarker
Copy link
Contributor

Board                    AP_Periph  blimp  bootloader  copter  heli  iofirmware  plane  rover  sub
CubeOrange-periph-heavy  *
Durandal                            -8     *           -8      -8                -8     -8     -8
Hitec-Airspeed           *
KakuteH7-bdshot                     0      *           0       0                 0      0      0
MatekF405                           0      *           0       0                 8      0      0
Pixhawk1-1M-bdshot                  0                  0       0                 0      0      0
f103-QiotekPeriph        *
f303-Universal           *
iomcu                                                                *
revo-mini                           0      *           0       0                 8      0      0
skyviper-v2450                                         0

@peterbarker peterbarker merged commit 0cb4955 into ArduPilot:master Sep 27, 2024
91 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants