emilib
|
#include <string_interning.hpp>
Public Member Functions | |
const char * | intern (const std::string &str) |
Not thread-safe. The allocated string will be freed when this StringInterner dies. | |
The StringInterner will allocate exactly one string for any unique input. This means that calling intern() twice with the same characters will result in the same pointer.
This is great for two things: