IFS (even in AT&T ksh93) are octets, so 'IFS=…' isn’t possible atm
This commit is contained in:
parent
09b96b8fc7
commit
22ff50fe55
28
mksh.1
28
mksh.1
@ -1,4 +1,4 @@
|
|||||||
.\" $MirOS: src/bin/mksh/mksh.1,v 1.198 2009/11/21 23:23:18 tg Exp $
|
.\" $MirOS: src/bin/mksh/mksh.1,v 1.199 2009/11/22 14:23:21 tg Exp $
|
||||||
.\" $OpenBSD: ksh.1,v 1.129 2009/05/28 06:09:06 jmc Exp $
|
.\" $OpenBSD: ksh.1,v 1.129 2009/05/28 06:09:06 jmc Exp $
|
||||||
.\"-
|
.\"-
|
||||||
.\" Copyright © 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
|
.\" Copyright © 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
|
||||||
@ -71,7 +71,7 @@
|
|||||||
.\" with -mandoc, it might implement .Mx itself, but we want to
|
.\" with -mandoc, it might implement .Mx itself, but we want to
|
||||||
.\" use our own definition. And .Dd must come *first*, always.
|
.\" use our own definition. And .Dd must come *first*, always.
|
||||||
.\"
|
.\"
|
||||||
.Dd $Mdocdate: November 21 2009 $
|
.Dd $Mdocdate: November 22 2009 $
|
||||||
.\"
|
.\"
|
||||||
.\" Check which macro package we use
|
.\" Check which macro package we use
|
||||||
.\"
|
.\"
|
||||||
@ -769,7 +769,7 @@ is set to what was read (leading/trailing space is stripped), and
|
|||||||
is executed.
|
is executed.
|
||||||
If a blank line (i.e. zero or more
|
If a blank line (i.e. zero or more
|
||||||
.Ev IFS
|
.Ev IFS
|
||||||
characters) is entered, the menu is reprinted without executing
|
octets) is entered, the menu is reprinted without executing
|
||||||
.Ar list .
|
.Ar list .
|
||||||
.Pp
|
.Pp
|
||||||
When
|
When
|
||||||
@ -1142,18 +1142,17 @@ the current value of the
|
|||||||
parameter.
|
parameter.
|
||||||
The
|
The
|
||||||
.Ev IFS
|
.Ev IFS
|
||||||
parameter specifies a list of characters which are used to break a string up
|
parameter specifies a list of octets which are used to break a string up
|
||||||
into several words; any characters from the set space, tab, and newline that
|
into several words; any octets from the set space, tab, and newline that
|
||||||
appear in the
|
appear in the
|
||||||
.Ev IFS
|
.Ev IFS
|
||||||
characters are called
|
octets are called
|
||||||
.Dq IFS whitespace .
|
.Dq IFS whitespace .
|
||||||
Sequences of one or more
|
Sequences of one or more
|
||||||
.Ev IFS
|
.Ev IFS
|
||||||
whitespace characters, in combination with zero or one
|
whitespace octets, in combination with zero or one
|
||||||
.Pf non- Ev IFS
|
.Pf non- Ev IFS
|
||||||
whitespace
|
whitespace octets, delimit a field.
|
||||||
characters, delimit a field.
|
|
||||||
As a special case, leading and trailing
|
As a special case, leading and trailing
|
||||||
.Ev IFS
|
.Ev IFS
|
||||||
whitespace and trailing
|
whitespace and trailing
|
||||||
@ -3578,13 +3577,10 @@ If
|
|||||||
.Ic read
|
.Ic read
|
||||||
is run in a loop such as
|
is run in a loop such as
|
||||||
.Ic while read foo; do ...; done
|
.Ic while read foo; do ...; done
|
||||||
then leading whitespace will be removed (IFS) and backslashes processed
|
then leading whitespace will be removed (IFS) and backslashes processed.
|
||||||
.Pf ( Fl r ) .
|
|
||||||
You might want to use
|
You might want to use
|
||||||
.Ic while IFS= read \-r foo; do ...; done
|
.Ic while IFS= read \-r foo; do ...; done
|
||||||
for pristine I/O (variable splitting, as in
|
for pristine I/O.
|
||||||
.Ic while IFS= read foo bar; do ...; done
|
|
||||||
is not possible though).
|
|
||||||
.Pp
|
.Pp
|
||||||
The inner loop will be executed in a subshell and variable changes
|
The inner loop will be executed in a subshell and variable changes
|
||||||
cannot be propagated if executed in a pipeline:
|
cannot be propagated if executed in a pipeline:
|
||||||
@ -4187,7 +4183,7 @@ is
|
|||||||
.Dv NULL
|
.Dv NULL
|
||||||
or unset, if it has embedded spaces (i.e.\&
|
or unset, if it has embedded spaces (i.e.\&
|
||||||
.Ev IFS
|
.Ev IFS
|
||||||
characters), or if it is a unary operator like
|
octets), or if it is a unary operator like
|
||||||
.Sq \&!
|
.Sq \&!
|
||||||
or
|
or
|
||||||
.Sq Fl n .
|
.Sq Fl n .
|
||||||
@ -4876,7 +4872,7 @@ respectively.
|
|||||||
The line is scrolled horizontally as necessary.
|
The line is scrolled horizontally as necessary.
|
||||||
.Pp
|
.Pp
|
||||||
Completed lines are pushed into the history, unless they begin with an
|
Completed lines are pushed into the history, unless they begin with an
|
||||||
IFS character or IFS white space, or are the same as the previous line.
|
IFS octet or IFS white space, or are the same as the previous line.
|
||||||
.Ss Emacs editing mode
|
.Ss Emacs editing mode
|
||||||
When the
|
When the
|
||||||
.Ic emacs
|
.Ic emacs
|
||||||
|
Loading…
x
Reference in New Issue
Block a user