Skip to content

Commit

Permalink
includes/std: Added hex::dec::lz4_decompress()
Browse files Browse the repository at this point in the history
  • Loading branch information
WerWolv committed Jul 7, 2024
1 parent 23b3c2b commit 4299243
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
11 changes: 11 additions & 0 deletions includes/hex/dec.pat
Original file line number Diff line number Diff line change
Expand Up @@ -60,5 +60,16 @@ namespace auto hex::dec {
fn zstd_decompress(ref auto pattern, std::mem::Section section) {
return builtin::hex::dec::zstd_decompress(pattern, section);
};

/**
Decompresses the bytes of a pattern into a section using the lz4 algorithm
@param pattern The pattern whose bytes should be decompressed
@param section The section to decompress the data into
@param frame Whether the data is framed or not
@return true if successful, false otherwise
*/
fn lz4_decompress(ref auto pattern, std::mem::Section section, bool frame = true) {
return builtin::hex::dec::lz4_decompress(pattern, section, frame);
};

}
4 changes: 2 additions & 2 deletions includes/std/math.pat
Original file line number Diff line number Diff line change
Expand Up @@ -317,8 +317,8 @@ namespace auto std::math {
*/
enum AccumulateOperation : u8 {
Add = 0,
Multiply = 1,
Modulo = 2,
Multiply = 1,
Modulo = 2,
Min = 3,
Max = 4
};
Expand Down

0 comments on commit 4299243

Please sign in to comment.