Tuesday, January 4, 2011

Special Variables

Per-filehandle Special Variables
These variables never need to be mentioned in a local()because they always refer to some value pertaining to the currently selected output filehandle - each filehandle keeps its own set of values.
VariableContentsMnemonic
$|If set to nonzero, forces a flush after every write or printWhen you want your pipes to be piping hot
$%Current page number% is page number in nroff
$=Current page length= has horizontal lines
$-Number of lines left on the pagelines_on_page - lines_printed
$~Name of the current report formatClosely related to $^
$^Name of the current top-of-page formatPoints to top of page

No comments: