Skip to content

Commit

Permalink
AK: Add nodiscard attribute to Base64 functions
Browse files Browse the repository at this point in the history
  • Loading branch information
ldm5180 authored and bgianfo committed Jul 4, 2022
1 parent 49042bf commit 56cabf8
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions AK/Base64.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,13 @@

namespace AK {

size_t calculate_base64_decoded_length(StringView);
[[nodiscard]] size_t calculate_base64_decoded_length(StringView);

size_t calculate_base64_encoded_length(ReadonlyBytes);
[[nodiscard]] size_t calculate_base64_encoded_length(ReadonlyBytes);

ErrorOr<ByteBuffer> decode_base64(StringView);

String encode_base64(ReadonlyBytes);
[[nodiscard]] ErrorOr<ByteBuffer> decode_base64(StringView);

[[nodiscard]] String encode_base64(ReadonlyBytes);
}

using AK::decode_base64;
Expand Down

0 comments on commit 56cabf8

Please sign in to comment.