Hi,
I just browsed libstdc++6-doc and stumbled over a string operation I haven't
noticed before: string::push_ba ck.
If for example I want to append single characters to an std::string, which
one would be better, or is there any difference at all:
mystr.push_back ( c );
or
mystr += c;
Any ideas? I used to use the latter one.
Regards,
Matthias
I just browsed libstdc++6-doc and stumbled over a string operation I haven't
noticed before: string::push_ba ck.
If for example I want to append single characters to an std::string, which
one would be better, or is there any difference at all:
mystr.push_back ( c );
or
mystr += c;
Any ideas? I used to use the latter one.
Regards,
Matthias
Comment