js: Tighten up ReplConsoleClient::trace() a little bit

Remove a bunch of unnecessary String copying.
This commit is contained in:
Andreas Kling 2020-05-05 11:48:57 +02:00
parent e4b9cf9b6c
commit 5c12f3fef0
Notes: sideshowbarker 2024-07-19 06:57:30 +09:00

View File

@ -437,8 +437,8 @@ public:
{
puts(interpreter().join_arguments().characters());
auto trace = interpreter().get_trace();
for (auto function_name : trace) {
if (String(function_name).is_empty())
for (auto& function_name : trace) {
if (function_name.is_empty())
function_name = "<anonymous>";
printf(" -> %s\n", function_name.characters());
}