ibm-information-center/dist/eclipse/plugins/i5OS.ic.rzahz_5.4.0.1/otherexp.htm

55 lines
1.9 KiB
HTML
Raw Permalink Normal View History

2024-04-02 14:02:31 +00:00
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html>
<head>
<meta name="generator" content="HTML Tidy, see www.w3.org">
<meta http-equiv="Content-Type" content=
"text/html; charset=utf-8">
<title>Other expansions</title>
<LINK rel="stylesheet" type="text/css" href="../rzahg/ic.css">
</HEAD>
<body bgcolor="#FFFFFF">
<!-- Java sync-link -->
<SCRIPT LANGUAGE="Javascript" SRC="../rzahg/synch.js" TYPE="text/javascript"></SCRIPT>
<h2>Field splitting</h2>
<p>After parameter expansion, command substitution, and arithmetic
expansion, <strong>qsh</strong> scans the results of expansions and
substitutions that did not occur in double quotation marks for field
splitting. Multiple fields can result.</p>
<p><strong>qsh</strong> treats each character of the <strong>
IFS</strong> variable as a delimiter and uses the delimiters to
split the results of parameter expansion and command substitution
into fields. If the value of the <strong>IFS</strong> variable is
null, no field splitting is performed.</p>
<h2><a name="path">Path name expansion</a></h2>
<p>When the noglob option is not set, path name expansion is
performed after field splitting is complete. Each word is viewed as
a series of <a href="pattern.htm">patterns</a>, separated by slashes.
The process of expansion replaces the word with the names of all
existing files whose names can be formed by replacing each pattern
with a string that matches the specified pattern. There are two
restrictions:</p>
<ol>
<li>a pattern cannot match a string containing a slash</li>
<li>a pattern cannot match a string starting with a period unless
the first character of the pattern is a period</li>
</ol>
<h2>Quote removal</h2>
<p>The quote characters, backslash (<strong>\</strong>), single
quotation mark (<strong>`</strong>), and double quotation mark (<strong>"</strong>),
are removed unless the character has been quoted.
</body>
</html>