diff options
| author | 2023-07-04 02:37:19 +0300 | |
|---|---|---|
| committer | 2023-07-04 02:37:19 +0300 | |
| commit | 99739da0169db308ecad28d99838a0f4574ae792 (patch) | |
| tree | e32aa2e91cb13be8c63ea68c53dc645c923971f9 /src/list.zig | |
| parent | Update for latest zig (diff) | |
| download | zup-99739da0169db308ecad28d99838a0f4574ae792.tar.gz zup-99739da0169db308ecad28d99838a0f4574ae792.tar.xz zup-99739da0169db308ecad28d99838a0f4574ae792.zip | |
Update for newest zig
Diffstat (limited to 'src/list.zig')
| -rw-r--r-- | src/list.zig | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/list.zig b/src/list.zig index 0a0fee9..9ff26c2 100644 --- a/src/list.zig +++ b/src/list.zig | |||
| @@ -19,7 +19,7 @@ pub const max_args = 0; | |||
| 19 | 19 | ||
| 20 | pub fn main(comptime Result: type, config: Config, res: Result) !void { | 20 | pub fn main(comptime Result: type, config: Config, res: Result) !void { |
| 21 | const allocator = config.allocator; | 21 | const allocator = config.allocator; |
| 22 | 22 | ||
| 23 | var list_active = res.args.active != 0; | 23 | var list_active = res.args.active != 0; |
| 24 | var list_available = res.args.available != 0; | 24 | var list_available = res.args.available != 0; |
| 25 | var list_installed = res.args.installed != 0; | 25 | var list_installed = res.args.installed != 0; |
| @@ -96,7 +96,7 @@ fn printList(allocator: Allocator, installations: Installations) !void { | |||
| 96 | list.appendAssumeCapacity(.{ .name = kv.key_ptr.*, .installation = kv.value_ptr.* }); | 96 | list.appendAssumeCapacity(.{ .name = kv.key_ptr.*, .installation = kv.value_ptr.* }); |
| 97 | } | 97 | } |
| 98 | 98 | ||
| 99 | std.sort.sort(InstallationAndName, list.items, {}, InstallationAndName.lessThan); | 99 | std.mem.sort(InstallationAndName, list.items, {}, InstallationAndName.lessThan); |
| 100 | 100 | ||
| 101 | const writer = std.io.getStdOut().writer(); | 101 | const writer = std.io.getStdOut().writer(); |
| 102 | for (list.items) |item| { | 102 | for (list.items) |item| { |