Zig 0.17.0-dev (Split by item)
This is an example of documentation generated by
ZigDoc , an alternative to Zig's built-in
Auto Doc feature. See also
examples in other modes/formats . The project being documented here (as the example) is the Zig library itself.
Zig › std/ › Build.zig › hashUserInputOptionsMap
hashUserInputOptionsMap
Build.hashUserInputOptionsMap
fn hashUserInputOptionsMap (allocator : Allocator , user_input_options : UserInputOptionsMap , hasher : *std .hash .Wyhash ) void
File
Code
fn hashUserInputOptionsMap (allocator : Allocator , user_input_options : UserInputOptionsMap , hasher : *std .hash .Wyhash ) void {
var ordered = std .array_list .Managed (OrderedUserInputOption ).init (allocator );
var it = user_input_options .iterator ();
while (it .next ()) |entry |
ordered .append (OrderedUserInputOption .fromUnordered (allocator , entry .value_ptr .*)) catch @panic ("OOM" );
std .mem .sortUnstable (OrderedUserInputOption , ordered .items , {}, OrderedUserInputOption .lessThan );
for (ordered .items ) |user_option |
user_option .hash (hasher );
}