Skip to content

Commit

Permalink
Update to latest version of zig
Browse files Browse the repository at this point in the history
  • Loading branch information
Hejsil committed Jan 9, 2024
1 parent 6aa5180 commit 9c23bcb
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
4 changes: 2 additions & 2 deletions clap.zig
Original file line number Diff line number Diff line change
Expand Up @@ -913,9 +913,9 @@ fn Arguments(
},
};

const name = longest.name[0..longest.name.len].*;
const name = longest.name[0..longest.name.len] ++ ""; // Adds null terminator
fields[i] = .{
.name = &name,
.name = name,
.type = @TypeOf(default_value),
.default_value = @ptrCast(&default_value),
.is_comptime = false,
Expand Down
6 changes: 6 additions & 0 deletions example/README.md.template
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ in the release notes.
* Print help message from parameter specification.
* Parse help message to parameter specification.

## API Reference

Automatically generated API Reference for the project
can be found at https://Hejsil.github.io/zig-clap.
Note that Zig autodoc is in beta; the website may be broken or incomplete.

## Examples

### `clap.parse`
Expand Down

0 comments on commit 9c23bcb

Please sign in to comment.