Skip to content

Commit

Permalink
Merge pull request #146 from Krvopije/master
Browse files Browse the repository at this point in the history
Fix for deprecated std.mem.copy
  • Loading branch information
vrischmann authored Dec 2, 2023
2 parents 0723e08 + 9a419c4 commit d697c0d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion query.zig
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ pub fn ParsedQuery(comptime query: []const u8) ParsedQueryState(query.len) {
.query_len = pos,
};

std.mem.copy(u8, &parsed_state.query, &buf);
std.mem.copyForwards(u8, &parsed_state.query, &buf);

return parsed_state;
}
Expand Down
2 changes: 1 addition & 1 deletion sqlite.zig
Original file line number Diff line number Diff line change
Expand Up @@ -1240,7 +1240,7 @@ pub fn Iterator(comptime Type: type) type {
if (data != null) {
const ptr = @as([*c]const u8, @ptrCast(data))[0..size];

mem.copy(u8, ret[0..], ptr);
mem.copyForwards(u8, ret[0..], ptr);
}
},
else => @compileError("cannot read into array of " ++ @typeName(arr.child)),
Expand Down

0 comments on commit d697c0d

Please sign in to comment.