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

Usermod F-string hygiene #4223

Merged
merged 1 commit into from
Oct 24, 2024
Merged

Conversation

willmmiles
Copy link
Collaborator

Another missing remnant of the end-oappend work: migrating usermods to use F() instead of F_STR() so as to pass the FlashStringHelper type along to the print() layer. Usermods calling oappend(F_STR("") on ESP8266 will crash without the shim in #4222. This could be considered an alternative fix: correct the source, rather than provide a workaround at a runtime cost.

Since oappend() is now strongly typed, pass the correct type.  This is a
step towards removing the extra shim logic on ESP8266.
@blazoncek
Copy link
Collaborator

IMO both are good. The other one will prevent misuse in the future.

Copy link
Collaborator

@blazoncek blazoncek left a comment

Choose a reason for hiding this comment

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

Has a go from my side.

@softhack007
Copy link
Collaborator

Thanks 👍 should be merged as it's a critical bugfix for 8266.

@willmmiles willmmiles merged commit c81ef26 into Aircoookie:0_15 Oct 24, 2024
20 checks passed
@willmmiles willmmiles deleted the f-string-hygiene branch October 24, 2024 19:23
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.

3 participants