unpod(str): any, [table]

Overview

unpod returns the decoded value, and the decoded metadata as a second result.

Arguments

str: string

The encoded string, generated by pod().

Returns

value: any

The value that was podded in str.

metadata: [table]

The metadata, if present, of the encoded string.

Examples

Sourced from the Picotron Manual

str = pod({4,5,6}, {desc = "an uninteresting sequence"})

content,metadata = unpod(str) -- returns content and metadata
?metadata.desc --  an uninteresting sequence
?content[1] -- 4