| ... | @@ -30,6 +30,11 @@ pub fn compile(comptime Ctx: type, alloc: std.mem.Allocator, writer: anytype, co | ... | @@ -30,6 +30,11 @@ pub fn compile(comptime Ctx: type, alloc: std.mem.Allocator, writer: anytype, co |
| 30 | try writer.writeAll("\n"); | 30 | try writer.writeAll("\n"); |
| 31 | } | 31 | } |
| 32 | | 32 | |
| | 33 | pub fn compileInner(alloc: std.mem.Allocator, writer: anytype, comptime value: astgen.Value, comptime opts: DoOptions, data: anytype) !void { |
| | 34 | try do(alloc, writer, value, data, data, opts); |
| | 35 | try writer.writeAll("\n"); |
| | 36 | } |
| | 37 | |
| 33 | pub const Writer = std.ArrayList(u8).Writer; | 38 | pub const Writer = std.ArrayList(u8).Writer; |
| 34 | | 39 | |
| 35 | inline fn do(alloc: std.mem.Allocator, writer: anytype, comptime value: astgen.Value, data: anytype, ctx: anytype, comptime opts: DoOptions) anyerror!void { | 40 | inline fn do(alloc: std.mem.Allocator, writer: anytype, comptime value: astgen.Value, data: anytype, ctx: anytype, comptime opts: DoOptions) anyerror!void { |