summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Vincent Rischmann2021-06-25 18:18:19 +0200
committerGravatar Vincent Rischmann2021-06-25 18:18:19 +0200
commitc3579fa48ab8e814058242e14d3b9d0dc4ff68c2 (patch)
treeba1543b344358c9046169830347847b3e8c5379c
parentquery: fix new compilation errors (diff)
downloadzig-sqlite-c3579fa48ab8e814058242e14d3b9d0dc4ff68c2.tar.gz
zig-sqlite-c3579fa48ab8e814058242e14d3b9d0dc4ff68c2.tar.xz
zig-sqlite-c3579fa48ab8e814058242e14d3b9d0dc4ff68c2.zip
fix 'unused variable' errors
-rw-r--r--sqlite.zig7
1 files changed, 1 insertions, 6 deletions
diff --git a/sqlite.zig b/sqlite.zig
index 3f43134..3c2471d 100644
--- a/sqlite.zig
+++ b/sqlite.zig
@@ -735,12 +735,6 @@ pub fn Iterator(comptime Type: type) type {
735 // The options must contain an `allocator` field which will be used to create a copy of the data. 735 // The options must contain an `allocator` field which will be used to create a copy of the data.
736 fn readBytes(self: *Self, comptime BytesType: type, allocator: *mem.Allocator, _i: usize, comptime mode: ReadBytesMode) !BytesType { 736 fn readBytes(self: *Self, comptime BytesType: type, allocator: *mem.Allocator, _i: usize, comptime mode: ReadBytesMode) !BytesType {
737 const i = @intCast(c_int, _i); 737 const i = @intCast(c_int, _i);
738 const type_info = @typeInfo(BytesType);
739
740 var ret: BytesType = switch (BytesType) {
741 Text, Blob => .{ .data = "" },
742 else => try dupeWithSentinel(BytesType, allocator, ""),
743 };
744 738
745 switch (mode) { 739 switch (mode) {
746 .Blob => { 740 .Blob => {
@@ -1250,6 +1244,7 @@ fn addTestData(db: *Db) !void {
1250 1244
1251test "sqlite: db init" { 1245test "sqlite: db init" {
1252 var db = try getTestDb(); 1246 var db = try getTestDb();
1247 _ = db;
1253} 1248}
1254 1249
1255test "sqlite: db pragma" { 1250test "sqlite: db pragma" {