================ @@ -63,12 +64,12 @@ const char DEV_NULL[] = "/dev/null"; namespace lldb_dap { -DAP::DAP(llvm::StringRef client_name, llvm::StringRef path, std::ofstream *log, - lldb::IOObjectSP input, lldb::IOObjectSP output, ReplMode repl_mode, - std::vector<std::string> pre_init_commands) - : client_name(client_name), debug_adapter_path(path), log(log), - input(std::move(input)), output(std::move(output)), - broadcaster("lldb-dap"), exception_breakpoints(), +DAP::DAP(llvm::StringRef path, std::ofstream *log, + const ReplMode default_repl_mode, + const std::vector<std::string> &pre_init_commands, + llvm::StringRef client_name, Transport &transport) + : debug_adapter_path(path), log(log), client_name(client_name), + transport(transport), broadcaster("lldb-dap"), exception_breakpoints(), pre_init_commands(std::move(pre_init_commands)), ---------------- labath wrote:
This `std::move` us a noop now that the argument is `const&`. if you want to keep it that way, then delete the move, though I actually think the original code was better as it lets the caller decide whether it needs its own copy of the argument or not (where as this guarantees there will be at least one copy operation) https://github.com/llvm/llvm-project/pull/130026 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits