summaryrefslogtreecommitdiffstats
path: root/src/common/lz4_compression.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/lz4_compression.h')
-rw-r--r--src/common/lz4_compression.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/common/lz4_compression.h b/src/common/lz4_compression.h
index 173f9b9ad..088ff5c91 100644
--- a/src/common/lz4_compression.h
+++ b/src/common/lz4_compression.h
@@ -18,7 +18,7 @@ namespace Common::Compression {
*
* @return the compressed data.
*/
-std::vector<u8> CompressDataLZ4(std::span<const u8> source);
+[[nodiscard]] std::vector<u8> CompressDataLZ4(std::span<const u8> source);
/**
* Utilizes the LZ4 subalgorithm LZ4HC with the specified compression level. Higher compression
@@ -31,7 +31,7 @@ std::vector<u8> CompressDataLZ4(std::span<const u8> source);
*
* @return the compressed data.
*/
-std::vector<u8> CompressDataLZ4HC(std::span<const u8> source, s32 compression_level);
+[[nodiscard]] std::vector<u8> CompressDataLZ4HC(std::span<const u8> source, s32 compression_level);
/**
* Utilizes the LZ4 subalgorithm LZ4HC with the highest possible compression level.
@@ -40,7 +40,7 @@ std::vector<u8> CompressDataLZ4HC(std::span<const u8> source, s32 compression_le
*
* @return the compressed data.
*/
-std::vector<u8> CompressDataLZ4HCMax(std::span<const u8> source);
+[[nodiscard]] std::vector<u8> CompressDataLZ4HCMax(std::span<const u8> source);
/**
* Decompresses a source memory region with LZ4 and returns the uncompressed data in a vector.
@@ -50,6 +50,7 @@ std::vector<u8> CompressDataLZ4HCMax(std::span<const u8> source);
*
* @return the decompressed data.
*/
-std::vector<u8> DecompressDataLZ4(const std::vector<u8>& compressed, std::size_t uncompressed_size);
+[[nodiscard]] std::vector<u8> DecompressDataLZ4(const std::vector<u8>& compressed,
+ std::size_t uncompressed_size);
} // namespace Common::Compression \ No newline at end of file