Skip to content

Comments

keyboard-service: fix syntax error in task macro#640

Merged
williampMSFT merged 1 commit intoOpenDevicePartnership:mainfrom
williampMSFT:user/williamp/kb-macro-fix
Dec 16, 2025
Merged

keyboard-service: fix syntax error in task macro#640
williampMSFT merged 1 commit intoOpenDevicePartnership:mainfrom
williampMSFT:user/williamp/kb-macro-fix

Conversation

@williampMSFT
Copy link
Contributor

#594 moved the responsibility for declaring async tasks from embedded-services to the application layer. To support this, some tasks that needed to be generic over a type (which is not directly supported by embassy) made into macros that emit a function that uses a concrete type. The application layer is required to call that macro and then implement a task that invokes the generated function.

However, in the case of the keyboard service, there appears to be a typo causing the name of the type identifier being passed into the macro to not match the name of the type identifier that is actually used in the macro, resulting in a compilation error whenever a user tries to actually invoke the macro. This change fixes the typo.

Copilot AI review requested due to automatic review settings December 16, 2025 01:37
@williampMSFT williampMSFT requested a review from a team as a code owner December 16, 2025 01:37
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR fixes a syntax error in the keyboard-service task macro where the macro parameter name didn't match its usage within the macro body. The issue would have caused compilation failures when users attempted to invoke the impl_host_request_task! macro.

Key Changes:

  • Renamed the macro parameter from $kb_int_ty:ty to $i2c_slave_ty:ty to match its actual usage in the macro body

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@jerrysxie jerrysxie added the bug Something isn't working label Dec 16, 2025
@williampMSFT williampMSFT enabled auto-merge (squash) December 16, 2025 17:30
@williampMSFT williampMSFT merged commit 1a56d16 into OpenDevicePartnership:main Dec 16, 2025
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

4 participants