[PATCH] D112247: Fix printEscapedString: Hex escape is \xHH, not \HH.
Matthias Kramm via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 21 11:00:10 PDT 2021
matthiaskramm created this revision.
matthiaskramm added a reviewer: Mogball.
Herald added subscribers: dexonsmith, hiraditya.
matthiaskramm requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D112247
Files:
llvm/lib/Support/StringExtras.cpp
Index: llvm/lib/Support/StringExtras.cpp
===================================================================
--- llvm/lib/Support/StringExtras.cpp
+++ llvm/lib/Support/StringExtras.cpp
@@ -67,7 +67,7 @@
else if (isPrint(C) && C != '"')
Out << C;
else
- Out << '\\' << hexdigit(C >> 4) << hexdigit(C & 0x0F);
+ Out << "\\x" << hexdigit(C >> 4) << hexdigit(C & 0x0F);
}
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D112247.381329.patch
Type: text/x-patch
Size: 403 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20211021/d58af8d5/attachment.bin>
More information about the llvm-commits
mailing list