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

Fix/Change: STATIC_QUEUE declares type rather than variable #80

Merged
merged 1 commit into from
Mar 14, 2025

Conversation

ventZl
Copy link
Owner

@ventZl ventZl commented Mar 14, 2025

The old behavior of STATIC_QUEUE macro was to define a variable. This is all nice and compact, but scales poorly if you need to access the queue from more than one compilation unit.

Thus this macro has been changed to macro STATIC_QUEUE_T which declares a type instead of variable. Thus the variable has to be defined by the developer.

The advantage of this approach is that you can declare the queue type in a header and then define / extern variables as needed in modules.

This is a breaking change for all the code which was already relying on STATIC_QUEUE.

In order to reveal such code early, we don't provide macro for backwards compatibility.

The old behavior of STATIC_QUEUE macro was to define a variable. This is
all nice and compact, but scales poorly if you need to access the queue
from more than one compilation unit.

Thus this macro has been changed to macro STATIC_QUEUE_T which declares
a type instead of variable. Thus the variable has to be defined by the
developer.

The advantage of this approach is that you can declare the queue type in
a header and then define / extern variables as needed in modules.

This is a breaking change for all the code which was already relying on
STATIC_QUEUE.

In order to reveal such code early, we don't provide macro for backwards
compatibility.
@ventZl ventZl merged commit f49c29e into master Mar 14, 2025
1 check passed
@ventZl ventZl deleted the feature/static-queue-type branch March 14, 2025 22:27
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.

1 participant