Test: dangling_cstr.cpp dangling_cstr.cpp: In function 'int main()': dangling_cstr.cpp:25:15: error: 'void Logger::log(const std::string&)' is private within this context 25 | logger.log("System started"); | ~~~~~~~~~~^~~~~~~~~~~~~~~~~~ dangling_cstr.cpp:16:10: note: declared private here 16 | void log(const std::string& msg) { | ^~~ dangling_cstr.cpp:26:15: error: 'void Logger::log(const std::string&)' is private within this context 26 | logger.log("Loading config"); | ~~~~~~~~~~^~~~~~~~~~~~~~~~~~ dangling_cstr.cpp:16:10: note: declared private here 16 | void log(const std::string& msg) { | ^~~ dangling_cstr.cpp:27:15: error: 'void Logger::log(const std::string&)' is private within this context 27 | logger.log("Ready"); | ~~~~~~~~~~^~~~~~~~~ dangling_cstr.cpp:16:10: note: declared private here 16 | void log(const std::string& msg) { | ^~~