dblaikie added a comment. In https://reviews.llvm.org/D49411#1164680, @labath wrote:
> Normally this would be clearly a good thing, but the added complication here > is that this function is part of a class hierarchy, and so this way you are > forcing every implementation to take a std::string, even though only one of > them cares about null-termination. > > In performance-critical code, llvm would use `llvm::Twine` as an argument, > which is able to avoid copies if the input string happens to be > null-terminated (`toNullTerminatedStringRef`). However, this code is hardly > that critical (and ScriptInterpreterPython is the only non-trivial class in > the hierarchy), so I don't think it really matters what you do here. Fair points all, Pavel - thanks for chiming in! https://reviews.llvm.org/D49411 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits