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_Mount: Conditionally define serial_instance to fix unused variable compile error #27607

Merged
merged 1 commit into from
Jul 24, 2024

Conversation

mduclehcm
Copy link
Contributor

Change:

  • Wrapped the definition of serial_instance with preprocessor directives to ensure it is only defined when necessary.
  • This resolves the compile error caused by the unused variable when no features requiring serial_instance are enabled.

@rmackay9
Copy link
Contributor

Thanks very much! I've tagged PeterB on this because he most likely knows best

Copy link
Contributor

@peterbarker peterbarker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGeTM.

I might have voided it just under where it was declared, but this looks good, thanks!

@rmackay9
Copy link
Contributor

rmackay9 commented Jul 24, 2024

Hi @mduclehcm,

Any chance you could rebase this on master? We don't normally allow "merge" commits.

Squashing all commits together would also be good

…le compile error

- Wrapped the definition of `serial_instance` with preprocessor directives to ensure it is only defined when necessary.
- This resolves the compile error caused by the unused variable when no features requiring `serial_instance` are enabled.
@peterbarker
Copy link
Contributor

I've corrected the commit list

@peterbarker peterbarker merged commit 25a406e into ArduPilot:master Jul 24, 2024
93 checks passed
@mduclehcm mduclehcm deleted the ducle/fix-unused-variable branch July 25, 2024 01:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants