Perl Programming/Keywords/open

From Wikibooks, open books for an open world
Jump to navigation Jump to search
Previous: oct Keywords Next: opendir

The open keyword[edit | edit source]

open is the Perl pragma to set the default input/output layers (PerlIO).

Syntax[edit | edit source]

  use open IN  => <info>, OUT => <info2>;

Examples[edit | edit source]

  use open IN  => ":crlf", OUT => ":bytes";
  []
  use open IO  => ":encoding(iso-8859-7)";

See also[edit | edit source]

Previous: oct Keywords Next: opendir