Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The problem with C++ strings for embedded is the heavy dependence on the heap for many operations and the constant copying of ROM literals into RAM objects. If your target platform is "embedded" with 1GiB+ RAM then you can work in systems programming mode and not care. If it's 32KiB, a heap may be too much of a liability.


I think you can probably avoid unnecessary copies by using std::string_view where possible instead of std::string .




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: