diff options
Diffstat (limited to 'vtab.zig')
| -rw-r--r-- | vtab.zig | 6 |
1 files changed, 3 insertions, 3 deletions
| @@ -210,7 +210,7 @@ pub const BestIndexBuilder = struct { | |||
| 210 | const res = Self{ | 210 | const res = Self{ |
| 211 | .allocator = allocator, | 211 | .allocator = allocator, |
| 212 | .index_info = index_info, | 212 | .index_info = index_info, |
| 213 | .id_str_buffer = std.ArrayList(u8).init(allocator), | 213 | .id_str_buffer = .empty, |
| 214 | .constraints = try allocator.alloc(Constraint, @intCast(index_info.nConstraint)), | 214 | .constraints = try allocator.alloc(Constraint, @intCast(index_info.nConstraint)), |
| 215 | .columns_used = @intCast(index_info.colUsed), | 215 | .columns_used = @intCast(index_info.colUsed), |
| 216 | .id = .{}, | 216 | .id = .{}, |
| @@ -1070,7 +1070,7 @@ const TestVirtualTable = struct { | |||
| 1070 | _ = self; | 1070 | _ = self; |
| 1071 | _ = diags; | 1071 | _ = diags; |
| 1072 | 1072 | ||
| 1073 | var id_str_writer = builder.id_str_buffer.writer(); | 1073 | var id_str_writer = builder.id_str_buffer.writer(builder.allocator); |
| 1074 | 1074 | ||
| 1075 | var argv_index: i32 = 0; | 1075 | var argv_index: i32 = 0; |
| 1076 | for (builder.constraints) |*constraint| { | 1076 | for (builder.constraints) |*constraint| { |
| @@ -1084,7 +1084,7 @@ const TestVirtualTable = struct { | |||
| 1084 | 1084 | ||
| 1085 | // | 1085 | // |
| 1086 | 1086 | ||
| 1087 | builder.id.str = try builder.id_str_buffer.toOwnedSlice(); | 1087 | builder.id.str = try builder.id_str_buffer.toOwnedSlice(builder.allocator); |
| 1088 | builder.estimated_cost = 200; | 1088 | builder.estimated_cost = 200; |
| 1089 | builder.estimated_rows = 200; | 1089 | builder.estimated_rows = 200; |
| 1090 | 1090 | ||