Commit 646268875e

hryx <codroid@gmail.com>
2019-06-28 07:16:31
Use new width format option
1 parent 2060c7c
Changed files (1)
src-self-hosted
src-self-hosted/translate_c.zig
@@ -740,7 +740,7 @@ fn escapeChar(c: u8) []const u8 {
         '\t' => return "\\t"[0..],
         else => {
             var buf: [4]u8 = undefined;
-            return std.fmt.bufPrint(buf[0..], "\\x{x2}", c) catch unreachable;
+            return std.fmt.bufPrint(buf[0..], "\\x{x:2}", c) catch unreachable;
         },
     }
 }