I guess that’s only strictly true for array-type data structures. If you were to repeatedly allocate 4 byte structures like a single integer that doesn‘t change in size I imagine this would be no problem at all in comparison.On any embedded device, repeated allocations and frees are obviously a bad idea. `operator+=` and `.append` on std::string are synonymous, so they only cause allocations at 50% marks.
If you control the std::string you're providing, its a good idea to `.reserve` a reasonable buffer size for the operation you'll be doing. Of course, you should also be checking it repeatedly for being over a threshold or its a classic DoS situation.
thanks for the info, I’ll probably have to try and fork the original library and make the appropriate changes. Currently it looks like it’s using the Arduino String implementation ( String(); ), so I’ll likely have to modify that.