Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
breuwi
· 8mo ago · 0 comments
[Deleted, misread]
Comments
[–]
Matheus28
8mo ago
Since C++11, data() is also required to be null terminated. Per your own source and cppreference.
[–]
breuwi
OP
8mo ago
LOL, I need to learn to click on the more modern tabs. Will delete comment.
[–]
beached_whale
8mo ago
std::string since C++ 11 guarantees the buffer is zero terminated. The reasoning being thread safety of const members.
https://eel.is/c++draft/basic.string#general-3