summaryrefslogtreecommitdiffstats
path: root/clangd/JSONRPCDispatcher.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clangd/JSONRPCDispatcher.cpp')
-rw-r--r--clangd/JSONRPCDispatcher.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/clangd/JSONRPCDispatcher.cpp b/clangd/JSONRPCDispatcher.cpp
index c67221a2..fec7cd7e 100644
--- a/clangd/JSONRPCDispatcher.cpp
+++ b/clangd/JSONRPCDispatcher.cpp
@@ -196,7 +196,7 @@ void clangd::runLanguageServerLoop(std::istream &In, JSONOutput &Out,
log(Context::empty(),
"Warning: Duplicate Content-Length header received. "
"The previous value for this message (" +
- std::to_string(ContentLength) + ") was ignored.\n");
+ llvm::Twine(ContentLength) + ") was ignored.\n");
}
llvm::getAsUnsignedInteger(LineRef.trim(), 0, ContentLength);
@@ -230,10 +230,9 @@ void clangd::runLanguageServerLoop(std::istream &In, JSONOutput &Out,
// If the stream is aborted before we read ContentLength bytes, In
// will have eofbit and failbit set.
if (!In) {
- log(Context::empty(), "Input was aborted. Read only " +
- std::to_string(In.gcount()) +
- " bytes of expected " +
- std::to_string(ContentLength) + ".\n");
+ log(Context::empty(),
+ "Input was aborted. Read only " + llvm::Twine(In.gcount()) +
+ " bytes of expected " + llvm::Twine(ContentLength) + ".\n");
break;
}