1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-04-25 20:02:37 +03:00
Max Prokhorov 0894b514cf
WString: direct operator overloads instead of StringSumHelper (#7781)
* wip

* huh, turns out String = 'c' did some weird stuff

* style

* allow "blah" + String, 'c' + String and F("...") + String

also, simplify const char* vs. __FlashStringHelper, and just always use _P functions

* shuffle things into .cpp

* trying to fix arduinojson

based on the implementation, we only need to specify that this symbol is a class

* fix accidental realloc, add test for operator+

basic chaining should work just like with master
comparing std::move() buffers won't work though, because we never allow
anything but `const StringSumHelper&` references

* fixup! fix accidental realloc, add test for operator+

* don't need another branch

* template +=(String / char* / numbers) and +(String, numbers / char*)

* nul after moving (isnt mem always zeroed tho?)

* check if lhs cant keep before switching to rhs

* fix String used to store struct data

`cannot bind bit-field '...' to 'signed char&'
`cannot bind bit-field '...' to 'unssigned char&'

noticed in both tasmota and espeasy, where this generates a webpage
content from some status struct containing bitfields

* style once more

* typo

* recover 444002180bca8e36b3014eaf5ecf5e690837b440
2021-03-21 14:40:25 +01:00
..
2019-05-14 00:09:54 +02:00
2019-05-14 00:09:54 +02:00
2021-03-14 17:36:20 -07:00
2019-05-14 00:09:54 +02:00
2020-09-25 11:12:39 +02:00
2020-05-26 20:04:49 -04:00
2021-03-14 17:36:20 -07:00
2021-03-14 17:36:20 -07:00
2021-03-14 17:36:20 -07:00
2020-04-23 12:15:21 -04:00
2021-03-14 17:36:20 -07:00
2021-03-14 17:36:20 -07:00
2021-03-14 17:36:20 -07:00
2021-03-14 17:36:20 -07:00
2021-03-07 08:14:07 -08:00
2020-09-25 11:12:39 +02:00
2019-05-14 00:09:54 +02:00
2021-03-14 17:36:20 -07:00
2021-03-14 17:36:20 -07:00
2019-05-14 00:09:54 +02:00
2019-11-04 23:14:35 -03:00
2020-04-23 12:15:21 -04:00
2021-03-14 17:36:20 -07:00
2019-05-14 00:09:54 +02:00
2021-03-14 17:36:20 -07:00
2021-03-14 17:36:20 -07:00
2021-03-14 17:36:20 -07:00
2021-03-14 17:36:20 -07:00
2019-05-14 00:09:54 +02:00
2021-03-14 17:36:20 -07:00
2021-03-14 17:36:20 -07:00
2020-07-09 09:59:49 -07:00
2014-12-01 00:34:28 +03:00