Documentation for method decode, assembled from the following types:
multi method decode(Blob: Str = 'UTF-8' --> Str)
Applies an encoding to turn the blob into a Str.
my Blob = "string".encode('utf-8');say .decode('utf-8'); # OUTPUT: «string␤»
On malformed utf-8
.decode will throw X::AdHoc. To handle sloppy utf-8 use