Just wondering if anyone knows if the string class in the STL is thread safe? And if so, around what time did it become thread safe?. Ive seen some code that uses its own string class and is thread safe. Im not sure if i should worrry about this when using the standard string class. Thanks
Nothing in the current standard is thread-safe. That doesn't mean there are no thread-safe implementations, it just means the standard doesn't require a compliant implementation to be thread-safe.
Just to add... I know of no STL string implementations that are thread-safe. All I'm aware of use
copy-on-write semantics which by nature are not thread-safe.