Name

unpack

Synopsis

unpack template, string
                  

Takes a string (string) representing a data structure and expands it into a list value, returning the list value. (unpack does the reverse of pack.) In a scalar context, it can be used to unpack a single value. The template has much the same format as the pack function—it specifies the order and type of the values to be unpacked. See pack for a more detailed description of template.

Get Perl in a Nutshell, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.