| ... | ... | @@ -122,13 +122,6 @@ fn doInner(alloc: std.mem.Allocator, writer: anytype, comptime value: astgen.Val |
| 122 | 122 | try writer.print("{d}", .{x}); |
| 123 | 123 | return; |
| 124 | 124 | } |
| 125 | | if (comptime extras.hasFn("format")(TO)) { |
| 126 | | return std.fmt.format(writer, "{}", .{x}); |
| 127 | | } |
| 128 | | if (comptime extras.hasFn("toString")(TO)) { |
| 129 | | try writer.writeAll(try x.toString(alloc)); |
| 130 | | return; |
| 131 | | } |
| 132 | 125 | if (comptime isArrayOf(u8)(TO)) { |
| 133 | 126 | if (repl.raw) { |
| 134 | 127 | try writer.writeAll(&x); |
| ... | ... | @@ -145,7 +138,7 @@ fn doInner(alloc: std.mem.Allocator, writer: anytype, comptime value: astgen.Val |
| 145 | 138 | if (!opts.escaped) try writer.writeAll(s); |
| 146 | 139 | return; |
| 147 | 140 | } |
| 148 | | @compileError(std.fmt.comptimePrint("pek: print {s}: unsupported type: {s}", .{ v, @typeName(TO) })); |
| 141 | return x.nprint(writer); |
| 149 | 142 | }, |
| 150 | 143 | .block => |v| { |
| 151 | 144 | const body = astgen.Value{ .body = v.body }; |