Zig 0.17.0-dev (Split by item)

Shortcut keys
?
Show these tips
S
Focus search field
Esc
Clear focus & close tips
U
Jump to source code
↑
Move up in search results
↓
Move down in search results
↵
Go to active search result
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 standard library. Public Function

weightToBitCount

Public Function
std.compress.zstd.Decompress.LiteralsSection.HuffmanTree.weightToBitCount
pub fn weightToBitCount(weight: u4, max_bit_count: u4) u4

Params

  • weight: u4
  • max_bit_count: u4

File

compress/zstd/Decompress.zig:1096
1096
1097
1098
        pub fn weightToBitCount(weight: u4, max_bit_count: u4) u4 {
            return if (weight == 0) 0 else ((max_bit_count + 1) - weight);
        }