-
Notifications
You must be signed in to change notification settings - Fork 7.5k
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
Fixed String(int64_t) #7765
Fixed String(int64_t) #7765
Conversation
38142dd
to
c2876d5
Compare
Rebased PR on latest master. Had to undo moved functions, rebase, move again, squash changes and force push. |
I built a test project to verify String integer conversion functionality. https://github.com/mrengineer7777/WStringTEST Testing against arduino-esp32 v2.0.5: Note the failures on Testing with proposed PR, including changes to WString from master: Note this PR resolves the failure on |
c2876d5
to
7e26c72
Compare
7e26c72
to
372544c
Compare
@SuGlider Ready for review |
WString Fix int64_t Fixed int64_t String support. Resolves issue espressif#7760. Background: sprintf on esp32 doesn't support "%lld" parameter. It's possible to recompile the underlying libraries to add that option, but I have an easier solution. This has already been solved in ESP8266 version of WString by replacing sprintf() with itoa/ltoa/lltoa. This PR does the following: Fixes integer print issues by replacing sprintf() with itoa/ltoa/lltoa Moves concat(long long num), concat(unsigned long long num) location (match ESP8266) Cleans up code formatting (matches ESP8266)
372544c
to
da088ef
Compare
Description of Change
Fixed int64_t String support.
Background:
sprintf on esp32 doesn't support "%lld" parameter. It's possible to recompile the underlying libraries to add that option. However this has already been solved in ESP8266 version of WString by replacing sprintf() with itoa/ltoa/lltoa.
This PR does the following:
Fixes integer print issues by replacing sprintf() with itoa/ltoa/lltoa
Moves concat(long long num), concat(unsigned long long num) location (match ESP8266)
Cleans up code formatting (matches ESP8266)
Tests scenarios
Tested on Arduino FeatherESP32 with v2.0.5 and current master.
Related links
Closes #7760