zig

fork of https://codeberg.org/ziglang/zig
Log | Files | Refs | README | LICENSE

commit e7d02eae4d99fbae11e91ddd7601e5ac2a392292 (tree)
parent b5badd112288b528d75085d82d5f7f1b109e87dc
Author: Jakub Konka <kubkon@jakubkonka.com>
Date:   Thu,  2 Jul 2020 20:54:57 +0200

Update lib/std/fs/test.zig

Co-authored-by: Joachim Schmidt <joachim.schmidt557@outlook.com>
Diffstat:
Mlib/std/fs/test.zig | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/std/fs/test.zig b/lib/std/fs/test.zig @@ -30,7 +30,7 @@ test "Dir.Iterator" { while (try iter.next()) |entry| { // We cannot just store `entry` as on Windows, we're re-using the name buffer // which means we'll actually share the `name` pointer between entries! - const name = try mem.dupe(&arena.allocator, u8, entry.name); + const name = try arena.allocator.dupe(u8, entry.name); try entries.append(Dir.Entry{ .name = name, .kind = entry.kind }); }