Avoid repeated construction of std::string from on_update functions.