</pre>
-<a name="Contents" href="#Contents"><h2>Contents</h2></a>
+<h2><a name="Contents" href="#Contents">Contents</a></h2>
<ul>
<li><a href="#Foreword">Foreword</a>
<li><a href="#Introduction">Introduction</a>
<!--page 9 -->
</ul>
-<a name="Foreword" href="#Foreword"><h2>Foreword</h2></a>
+<h2><a name="Foreword" href="#Foreword">Foreword</a></h2>
<p><!--para 1 -->
ISO (the International Organization for Standardization) and IEC (the International
Electrotechnical Commission) form the specialized system for worldwide
also for information only.
<!--page 12 -->
-<a name="Introduction" href="#Introduction"><h2>Introduction</h2></a>
+<h2><a name="Introduction" href="#Introduction">Introduction</a></h2>
<p><!--para 1 -->
With the introduction of new devices and extended character sets, new features may be
added to this International Standard. Subclauses in the language and library clauses warn
-<a name="1" href="#1"><h2>1. Scope</h2></a>
+<h2><a name="1" href="#1">1. Scope</a></h2>
<p><!--para 1 -->
This International Standard specifies the form and establishes the interpretation of
programs written in the C programming language.<sup><a href="#note1"><b>1)</b></a></sup> It specifies
data-processing systems. It is intended for use by implementors and programmers.
</small>
-<a name="2" href="#2"><h2>2. Normative references</h2></a>
+<h2><a name="2" href="#2">2. Normative references</a></h2>
<p><!--para 1 -->
The following normative documents contain provisions which, through reference in this
text, constitute provisions of this International Standard. For dated references,
designated IEC 559:1989).
<!--page 15 -->
-<a name="3" href="#3"><h2>3. Terms, definitions, and symbols</h2></a>
+<h2><a name="3" href="#3">3. Terms, definitions, and symbols</a></h2>
<p><!--para 1 -->
For the purposes of this International Standard, the following definitions apply. Other
terms are defined where they appear in italic type or on the left side of a syntax rule.
Standard are to be interpreted according to ISO/IEC 2382-1. Mathematical symbols not
defined in this International Standard are to be interpreted according to ISO 31-11.
-<a name="3.1" href="#3.1"><h3>3.1</h3></a>
+<h3><a name="3.1" href="#3.1">3.1</a></h3>
<p><!--para 1 -->
- access
+<b> access</b><br>
<execution-time action> to read or modify the value of an object
<p><!--para 2 -->
NOTE 1 Where only one of these two actions is meant, ''read'' or ''modify'' is used.
NOTE 3 Expressions that are not evaluated do not access objects.
-<a name="3.2" href="#3.2"><h3>3.2</h3></a>
+<h3><a name="3.2" href="#3.2">3.2</a></h3>
<p><!--para 1 -->
- alignment
+<b> alignment</b><br>
requirement that objects of a particular type be located on storage boundaries with
addresses that are particular multiples of a byte address
-<a name="3.3" href="#3.3"><h3>3.3</h3></a>
+<h3><a name="3.3" href="#3.3">3.3</a></h3>
<p><!--para 1 -->
- argument
- actual argument
- actual parameter (deprecated)
+<b> argument</b><br>
+ actual argument<br>
+ actual parameter (deprecated)<br>
expression in the comma-separated list bounded by the parentheses in a function call
expression, or a sequence of preprocessing tokens in the comma-separated list bounded
by the parentheses in a function-like macro invocation
-<a name="3.4" href="#3.4"><h3>3.4</h3></a>
+<h3><a name="3.4" href="#3.4">3.4</a></h3>
<p><!--para 1 -->
- behavior
+<b> behavior</b><br>
external appearance or action
-<a name="3.4.1" href="#3.4.1"><h4>3.4.1</h4></a>
+<h4><a name="3.4.1" href="#3.4.1">3.4.1</a></h4>
<p><!--para 1 -->
- implementation-defined behavior
+<b> implementation-defined behavior</b><br>
unspecified behavior where each implementation documents how the choice is made
<p><!--para 2 -->
EXAMPLE An example of implementation-defined behavior is the propagation of the high-order bit
when a signed integer is shifted right.
-<a name="3.4.2" href="#3.4.2"><h4>3.4.2</h4></a>
+<h4><a name="3.4.2" href="#3.4.2">3.4.2</a></h4>
<p><!--para 1 -->
- locale-specific behavior
+<b> locale-specific behavior</b><br>
behavior that depends on local conventions of nationality, culture, and language that each
implementation documents
<!--page 16 -->
characters other than the 26 lowercase Latin letters.
-<a name="3.4.3" href="#3.4.3"><h4>3.4.3</h4></a>
+<h4><a name="3.4.3" href="#3.4.3">3.4.3</a></h4>
<p><!--para 1 -->
- undefined behavior
+<b> undefined behavior</b><br>
behavior, upon use of a nonportable or erroneous program construct or of erroneous data,
for which this International Standard imposes no requirements
<p><!--para 2 -->
EXAMPLE An example of undefined behavior is the behavior on integer overflow.
-<a name="3.4.4" href="#3.4.4"><h4>3.4.4</h4></a>
+<h4><a name="3.4.4" href="#3.4.4">3.4.4</a></h4>
<p><!--para 1 -->
- unspecified behavior
+<b> unspecified behavior</b><br>
use of an unspecified value, or other behavior where this International Standard provides
two or more possibilities and imposes no further requirements on which is chosen in any
instance
evaluated.
-<a name="3.5" href="#3.5"><h3>3.5</h3></a>
+<h3><a name="3.5" href="#3.5">3.5</a></h3>
<p><!--para 1 -->
- bit
+<b> bit</b><br>
unit of data storage in the execution environment large enough to hold an object that may
have one of two values
<p><!--para 2 -->
NOTE It need not be possible to express the address of each individual bit of an object.
-<a name="3.6" href="#3.6"><h3>3.6</h3></a>
+<h3><a name="3.6" href="#3.6">3.6</a></h3>
<p><!--para 1 -->
- byte
+<b> byte</b><br>
addressable unit of data storage large enough to hold any member of the basic character
set of the execution environment
<p><!--para 2 -->
bit.
-<a name="3.7" href="#3.7"><h3>3.7</h3></a>
+<h3><a name="3.7" href="#3.7">3.7</a></h3>
<p><!--para 1 -->
- character
+<b> character</b><br>
<abstract> member of a set of elements used for the organization, control, or
representation of data
-<a name="3.7.1" href="#3.7.1"><h4>3.7.1</h4></a>
+<h4><a name="3.7.1" href="#3.7.1">3.7.1</a></h4>
<p><!--para 1 -->
- character
+<b> character</b><br>
single-byte character
<C> bit representation that fits in a byte
<!--page 17 -->
-<a name="3.7.2" href="#3.7.2"><h4>3.7.2</h4></a>
+<h4><a name="3.7.2" href="#3.7.2">3.7.2</a></h4>
<p><!--para 1 -->
- multibyte character
+<b> multibyte character</b><br>
sequence of one or more bytes representing a member of the extended character set of
either the source or the execution environment
<p><!--para 2 -->
NOTE The extended character set is a superset of the basic character set.
-<a name="3.7.3" href="#3.7.3"><h4>3.7.3</h4></a>
+<h4><a name="3.7.3" href="#3.7.3">3.7.3</a></h4>
<p><!--para 1 -->
- wide character
+<b> wide character</b><br>
bit representation that fits in an object of type wchar_t, capable of representing any
character in the current locale
-<a name="3.8" href="#3.8"><h3>3.8</h3></a>
+<h3><a name="3.8" href="#3.8">3.8</a></h3>
<p><!--para 1 -->
- constraint
+<b> constraint</b><br>
restriction, either syntactic or semantic, by which the exposition of language elements is
to be interpreted
-<a name="3.9" href="#3.9"><h3>3.9</h3></a>
+<h3><a name="3.9" href="#3.9">3.9</a></h3>
<p><!--para 1 -->
- correctly rounded result
+<b> correctly rounded result</b><br>
representation in the result format that is nearest in value, subject to the current rounding
mode, to what the result would be given unlimited range and precision
-<a name="3.10" href="#3.10"><h3>3.10</h3></a>
+<h3><a name="3.10" href="#3.10">3.10</a></h3>
<p><!--para 1 -->
- diagnostic message
+<b> diagnostic message</b><br>
message belonging to an implementation-defined subset of the implementation's message
output
-<a name="3.11" href="#3.11"><h3>3.11</h3></a>
+<h3><a name="3.11" href="#3.11">3.11</a></h3>
<p><!--para 1 -->
- forward reference
+<b> forward reference</b><br>
reference to a later subclause of this International Standard that contains additional
information relevant to this subclause
-<a name="3.12" href="#3.12"><h3>3.12</h3></a>
+<h3><a name="3.12" href="#3.12">3.12</a></h3>
<p><!--para 1 -->
- implementation
+<b> implementation</b><br>
particular set of software, running in a particular translation environment under particular
control options, that performs translation of programs for, and supports execution of
functions in, a particular execution environment
-<a name="3.13" href="#3.13"><h3>3.13</h3></a>
+<h3><a name="3.13" href="#3.13">3.13</a></h3>
<p><!--para 1 -->
- implementation limit
+<b> implementation limit</b><br>
restriction imposed upon programs by the implementation
-<a name="3.14" href="#3.14"><h3>3.14</h3></a>
+<h3><a name="3.14" href="#3.14">3.14</a></h3>
<p><!--para 1 -->
- object
+<b> object</b><br>
region of data storage in the execution environment, the contents of which can represent
values
<!--page 18 -->
NOTE When referenced, an object may be interpreted as having a particular type; see <a href="#6.3.2.1">6.3.2.1</a>.
-<a name="3.15" href="#3.15"><h3>3.15</h3></a>
+<h3><a name="3.15" href="#3.15">3.15</a></h3>
<p><!--para 1 -->
- parameter
+<b> parameter</b><br>
formal parameter
formal argument (deprecated)
object declared as part of a function declaration or definition that acquires a value on
entry to the function, or an identifier from the comma-separated list bounded by the
parentheses immediately following the macro name in a function-like macro definition
-<a name="3.16" href="#3.16"><h3>3.16</h3></a>
+<h3><a name="3.16" href="#3.16">3.16</a></h3>
<p><!--para 1 -->
- recommended practice
+<b> recommended practice</b><br>
specification that is strongly recommended as being in keeping with the intent of the
standard, but that may be impractical for some implementations
-<a name="3.17" href="#3.17"><h3>3.17</h3></a>
+<h3><a name="3.17" href="#3.17">3.17</a></h3>
<p><!--para 1 -->
- value
+<b> value</b><br>
precise meaning of the contents of an object when interpreted as having a specific type
-<a name="3.17.1" href="#3.17.1"><h4>3.17.1</h4></a>
+<h4><a name="3.17.1" href="#3.17.1">3.17.1</a></h4>
<p><!--para 1 -->
- implementation-defined value
+<b> implementation-defined value</b><br>
unspecified value where each implementation documents how the choice is made
-<a name="3.17.2" href="#3.17.2"><h4>3.17.2</h4></a>
+<h4><a name="3.17.2" href="#3.17.2">3.17.2</a></h4>
<p><!--para 1 -->
- indeterminate value
+<b> indeterminate value</b><br>
either an unspecified value or a trap representation
-<a name="3.17.3" href="#3.17.3"><h4>3.17.3</h4></a>
+<h4><a name="3.17.3" href="#3.17.3">3.17.3</a></h4>
<p><!--para 1 -->
- unspecified value
+<b> unspecified value</b><br>
valid value of the relevant type where this International Standard imposes no
requirements on which value is chosen in any instance
<p><!--para 2 -->
NOTE An unspecified value cannot be a trap representation.
-<a name="3.18" href="#3.18"><h3>3.18</h3></a>
+<h3><a name="3.18" href="#3.18">3.18</a></h3>
<p><!--para 1 -->
- ??? x???
+<b> [^ x ^]</b><br>
ceiling of x: the least integer greater than or equal to x
<p><!--para 2 -->
- EXAMPLE ???2.4??? is 3, ???-2.4??? is -2.
+ EXAMPLE [^2.4^] is 3, [^-2.4^] is -2.
-<a name="3.19" href="#3.19"><h3>3.19</h3></a>
+<h3><a name="3.19" href="#3.19">3.19</a></h3>
<p><!--para 1 -->
- ??? x???
+<b> [_ x _]</b><br>
floor of x: the greatest integer less than or equal to x
<p><!--para 2 -->
- EXAMPLE ???2.4??? is 2, ???-2.4??? is -3.
+ EXAMPLE [_2.4_] is 2, [_-2.4_] is -3.
<!--page 19 -->
-<a name="4" href="#4"><h2>4. Conformance</h2></a>
+<h2><a name="4" href="#4">4. Conformance</a></h2>
<p><!--para 1 -->
In this International Standard, ''shall'' is to be interpreted as a requirement on an
implementation or on a program; conversely, ''shall not'' is to be interpreted as a
implementation.
</small>
-<a name="5" href="#5"><h2>5. Environment</h2></a>
+<h2><a name="5" href="#5">5. Environment</a></h2>
<p><!--para 1 -->
An implementation translates C source files and executes C programs in two data-
processing-system environments, which will be called the translation environment and
<p><b> Forward references</b>: In this clause, only a few of many possible forward references
have been noted.
-<a name="5.1" href="#5.1"><h3>5.1 Conceptual models</h3></a>
+<h3><a name="5.1" href="#5.1">5.1 Conceptual models</a></h3>
-<a name="5.1.1" href="#5.1.1"><h4>5.1.1 Translation environment</h4></a>
+<h4><a name="5.1.1" href="#5.1.1">5.1.1 Translation environment</a></h4>
-<a name="5.1.1.1" href="#5.1.1.1"><h5>5.1.1.1 Program structure</h5></a>
+<h5><a name="5.1.1.1" href="#5.1.1.1">5.1.1.1 Program structure</a></h5>
<p><!--para 1 -->
A C program need not all be translated at the same time. The text of the program is kept
in units called source files, (or preprocessing files) in this International Standard. A
<p><b> Forward references</b>: linkages of identifiers (<a href="#6.2.2">6.2.2</a>), external definitions (<a href="#6.9">6.9</a>),
preprocessing directives (<a href="#6.10">6.10</a>).
-<a name="5.1.1.2" href="#5.1.1.2"><h5>5.1.1.2 Translation phases</h5></a>
+<h5><a name="5.1.1.2" href="#5.1.1.2">5.1.1.2 Translation phases</a></h5>
<p><!--para 1 -->
The precedence among the syntax rules of translation is specified by the following
phases.<sup><a href="#note5"><b>5)</b></a></sup>
character.
</small>
-<a name="5.1.1.3" href="#5.1.1.3"><h5>5.1.1.3 Diagnostics</h5></a>
+<h5><a name="5.1.1.3" href="#5.1.1.3">5.1.1.3 Diagnostics</a></h5>
<p><!--para 1 -->
A conforming implementation shall produce at least one diagnostic message (identified in
an implementation-defined manner) if a preprocessing translation unit or translation unit
valid program is still correctly translated. It may also successfully translate an invalid program.
</small>
-<a name="5.1.2" href="#5.1.2"><h4>5.1.2 Execution environments</h4></a>
+<h4><a name="5.1.2" href="#5.1.2">5.1.2 Execution environments</a></h4>
<p><!--para 1 -->
Two execution environments are defined: freestanding and hosted. In both cases,
program startup occurs when a designated C function is called by the execution
environment.
<p><b> Forward references</b>: storage durations of objects (<a href="#6.2.4">6.2.4</a>), initialization (<a href="#6.7.8">6.7.8</a>).
-<a name="5.1.2.1" href="#5.1.2.1"><h5>5.1.2.1 Freestanding environment</h5></a>
+<h5><a name="5.1.2.1" href="#5.1.2.1">5.1.2.1 Freestanding environment</a></h5>
<p><!--para 1 -->
In a freestanding environment (in which C program execution may take place without any
benefit of an operating system), the name and type of the function called at program
The effect of program termination in a freestanding environment is implementation-
defined.
-<a name="5.1.2.2" href="#5.1.2.2"><h5>5.1.2.2 Hosted environment</h5></a>
+<h5><a name="5.1.2.2" href="#5.1.2.2">5.1.2.2 Hosted environment</a></h5>
<p><!--para 1 -->
A hosted environment need not be provided, but shall conform to the following
specifications if present.
<!--page 24 -->
-<a name="5.1.2.2.1" href="#5.1.2.2.1"><h5>5.1.2.2.1 Program startup</h5></a>
+<h5><a name="5.1.2.2.1" href="#5.1.2.2.1">5.1.2.2.1 Program startup</a></h5>
<p><!--para 1 -->
The function called at program startup is named main. The implementation declares no
prototype for this function. It shall be defined with a return type of int and with no
char ** argv, and so on.
</small>
-<a name="5.1.2.2.2" href="#5.1.2.2.2"><h5>5.1.2.2.2 Program execution</h5></a>
+<h5><a name="5.1.2.2.2" href="#5.1.2.2.2">5.1.2.2.2 Program execution</a></h5>
<p><!--para 1 -->
In a hosted environment, a program may use all the functions, macros, type definitions,
and objects described in the library clause (clause 7).
<!--page 25 -->
-<a name="5.1.2.2.3" href="#5.1.2.2.3"><h5>5.1.2.2.3 Program termination</h5></a>
+<h5><a name="5.1.2.2.3" href="#5.1.2.2.3">5.1.2.2.3 Program termination</a></h5>
<p><!--para 1 -->
If the return type of the main function is a type compatible with int, a return from the
initial call to the main function is equivalent to calling the exit function with the value
will have ended in the former case, even where they would not have in the latter.
</small>
-<a name="5.1.2.3" href="#5.1.2.3"><h5>5.1.2.3 Program execution</h5></a>
+<h5><a name="5.1.2.3" href="#5.1.2.3">5.1.2.3 Program execution</a></h5>
<p><!--para 1 -->
The semantic descriptions in this International Standard describe the behavior of an
abstract machine in which issues of optimization are irrelevant.
effects matter, freeing the implementations in other cases.
</small>
-<a name="5.2" href="#5.2"><h3>5.2 Environmental considerations</h3></a>
+<h3><a name="5.2" href="#5.2">5.2 Environmental considerations</a></h3>
-<a name="5.2.1" href="#5.2.1"><h4>5.2.1 Character sets</h4></a>
+<h4><a name="5.2.1" href="#5.2.1">5.2.1 Character sets</a></h4>
<p><!--para 1 -->
Two sets of characters and their associated collating sequences shall be defined: the set in
which source files are written (the source character set), and the set interpreted in the
<p><b> Forward references</b>: universal character names (<a href="#6.4.3">6.4.3</a>), character constants (<a href="#6.4.4.4">6.4.4.4</a>),
preprocessing directives (<a href="#6.10">6.10</a>), string literals (<a href="#6.4.5">6.4.5</a>), comments (<a href="#6.4.9">6.4.9</a>), string (<a href="#7.1.1">7.1.1</a>).
-<a name="5.2.1.1" href="#5.2.1.1"><h5>5.2.1.1 Trigraph sequences</h5></a>
+<h5><a name="5.2.1.1" href="#5.2.1.1">5.2.1.1 Trigraph sequences</a></h5>
<p><!--para 1 -->
Before any other processing takes place, each occurrence of one of the following
sequences of three characters (called trigraph sequences<sup><a href="#note12"><b>12)</b></a></sup>) is replaced with the
described in ISO/IEC 646, which is a subset of the seven-bit US ASCII code set.
</small>
-<a name="5.2.1.2" href="#5.2.1.2"><h5>5.2.1.2 Multibyte characters</h5></a>
+<h5><a name="5.2.1.2" href="#5.2.1.2">5.2.1.2 Multibyte characters</a></h5>
<p><!--para 1 -->
The source character set may contain multibyte characters, used to represent members of
the extended character set. The execution character set may also contain multibyte
of a sequence of valid multibyte characters.
</ul>
-<a name="5.2.2" href="#5.2.2"><h4>5.2.2 Character display semantics</h4></a>
+<h4><a name="5.2.2" href="#5.2.2">5.2.2 Character display semantics</a></h4>
<p><!--para 1 -->
The active position is that location on a display device where the next character output by
the fputc function would appear. The intent of writing a printing character (as defined
<p><!--para 2 -->
Alphabetic escape sequences representing nongraphic characters in the execution
character set are intended to produce actions on display devices as follows:
- \a (alert) Produces an audible or visible alert without changing the active position.
- \b (backspace) Moves the active position to the previous position on the current line. If
-<pre>
+<dl>
+<dt> \a <dd>(alert) Produces an audible or visible alert without changing the active position.
+<dt> \b <dd>(backspace) Moves the active position to the previous position on the current line. If
the active position is at the initial position of a line, the behavior of the display
- device is unspecified.</pre>
- \f ( form feed) Moves the active position to the initial position at the start of the next
-<pre>
- logical page.</pre>
- \n (new line) Moves the active position to the initial position of the next line.
- \r (carriage return) Moves the active position to the initial position of the current line.
- \t (horizontal tab) Moves the active position to the next horizontal tabulation position
-<pre>
+ device is unspecified.
+<dt> \f <dd>( form feed) Moves the active position to the initial position at the start of the next
+ logical page.
+<dt> \n <dd>(new line) Moves the active position to the initial position of the next line.
+<dt> \r <dd>(carriage return) Moves the active position to the initial position of the current line.
+<dt> \t <dd>(horizontal tab) Moves the active position to the next horizontal tabulation position
on the current line. If the active position is at or past the last defined horizontal
- tabulation position, the behavior of the display device is unspecified.</pre>
- \v (vertical tab) Moves the active position to the initial position of the next vertical
+ tabulation position, the behavior of the display device is unspecified.
+<dt> \v <dd>(vertical tab) Moves the active position to the initial position of the next vertical
<!--page 32 -->
-<p><!--para 3 -->
-<pre>
tabulation position. If the active position is at or past the last defined vertical
- tabulation position, the behavior of the display device is unspecified.</pre>
+ tabulation position, the behavior of the display device is unspecified.
+</dl>
+<p><!--para 3 -->
Each of these escape sequences shall produce a unique implementation-defined value
which can be stored in a single char object. The external representations in a text file
need not be identical to the internal representations, and are outside the scope of this
International Standard.
<p><b> Forward references</b>: the isprint function (<a href="#7.4.1.8">7.4.1.8</a>), the fputc function (<a href="#7.19.7.3">7.19.7.3</a>).
-<a name="5.2.3" href="#5.2.3"><h4>5.2.3 Signals and interrupts</h4></a>
+<h4><a name="5.2.3" href="#5.2.3">5.2.3 Signals and interrupts</a></h4>
<p><!--para 1 -->
Functions shall be implemented such that they may be interrupted at any time by a signal,
or may be called by a signal handler, or both, with no alteration to earlier, but still active,
image (the instructions that compose the executable representation of a function) on a
per-invocation basis.
-<a name="5.2.4" href="#5.2.4"><h4>5.2.4 Environmental limits</h4></a>
+<h4><a name="5.2.4" href="#5.2.4">5.2.4 Environmental limits</a></h4>
<p><!--para 1 -->
Both the translation and execution environments constrain the implementation of
language translators and libraries. The following summarizes the language-related
environmental limits on a conforming implementation; the library-related limits are
discussed in clause 7.
-<a name="5.2.4.1" href="#5.2.4.1"><h5>5.2.4.1 Translation limits</h5></a>
+<h5><a name="5.2.4.1" href="#5.2.4.1">5.2.4.1 Translation limits</a></h5>
<p><!--para 1 -->
The implementation shall be able to translate and execute at least one program that
contains at least one instance of every one of the following limits:<sup><a href="#note13"><b>13)</b></a></sup>
<p><small><a name="note14" href="#note14">14)</a> See ''future language directions'' (<a href="#6.11.3">6.11.3</a>).
</small>
-<a name="5.2.4.2" href="#5.2.4.2"><h5>5.2.4.2 Numerical limits</h5></a>
+<h5><a name="5.2.4.2" href="#5.2.4.2">5.2.4.2 Numerical limits</a></h5>
<p><!--para 1 -->
An implementation is required to document all the limits specified in this subclause,
which are specified in the headers <a href="#7.10"><limits.h></a> and <a href="#7.7"><float.h></a>. Additional limits are
specified in <a href="#7.18"><stdint.h></a>.
<p><b> Forward references</b>: integer types <a href="#7.18"><stdint.h></a> (<a href="#7.18">7.18</a>).
-<a name="5.2.4.2.1" href="#5.2.4.2.1"><h5>5.2.4.2.1 Sizes of integer types <limits.h></h5></a>
+<h5><a name="5.2.4.2.1" href="#5.2.4.2.1">5.2.4.2.1 Sizes of integer types <limits.h></a></h5>
<p><!--para 1 -->
The values given below shall be replaced by constant expressions suitable for use in #if
preprocessing directives. Moreover, except for CHAR_BIT and MB_LEN_MAX, the
(absolute value) to those shown, with the same sign.
<ul>
<li> number of bits for smallest object that is not a bit-field (byte)
- CHAR_BIT 8
+<pre> CHAR_BIT 8</pre>
<li> minimum value for an object of type signed char
- SCHAR_MIN -127 // -(27 - 1)
+<pre> SCHAR_MIN -127 // -(2<sup>7</sup> - 1)</pre>
<li> maximum value for an object of type signed char
- SCHAR_MAX +127 // 27 - 1
+<pre> SCHAR_MAX +127 // 2<sup>7</sup> - 1</pre>
<li> maximum value for an object of type unsigned char
- UCHAR_MAX 255 // 28 - 1
+<pre> UCHAR_MAX 255 // 2<sup>8</sup> - 1</pre>
<li> minimum value for an object of type char
- CHAR_MIN see below
+<pre> CHAR_MIN see below</pre>
<li> maximum value for an object of type char
- CHAR_MAX see below
+<pre> CHAR_MAX see below</pre>
<li> maximum number of bytes in a multibyte character, for any supported locale
- MB_LEN_MAX 1
+<pre> MB_LEN_MAX 1</pre>
<li> minimum value for an object of type short int
- SHRT_MIN -32767 // -(215 - 1)
+<pre> SHRT_MIN -32767 // -(2<sup>15</sup> - 1)</pre>
<li> maximum value for an object of type short int
- SHRT_MAX +32767 // 215 - 1
+<pre> SHRT_MAX +32767 // 2<sup>15</sup> - 1</pre>
<li> maximum value for an object of type unsigned short int
- USHRT_MAX 65535 // 216 - 1
+<pre> USHRT_MAX 65535 // 2<sup>16</sup> - 1</pre>
<li> minimum value for an object of type int
- INT_MIN -32767 // -(215 - 1)
+<pre> INT_MIN -32767 // -(2<sup>15</sup> - 1)</pre>
<li> maximum value for an object of type int
- INT_MAX +32767 // 215 - 1
+<pre> INT_MAX +32767 // 2<sup>15</sup> - 1</pre>
<li> maximum value for an object of type unsigned int
- UINT_MAX 65535 // 216 - 1
+<pre> UINT_MAX 65535 // 2<sup>16</sup> - 1</pre>
<li> minimum value for an object of type long int
- LONG_MIN -2147483647 // -(231 - 1)
+<pre> LONG_MIN -2147483647 // -(2<sup>31</sup> - 1)</pre>
<li> maximum value for an object of type long int
- LONG_MAX +2147483647 // 231 - 1
+<pre> LONG_MAX +2147483647 // 2<sup>31</sup> - 1</pre>
<li> maximum value for an object of type unsigned long int
- ULONG_MAX 4294967295 // 232 - 1
+<pre> ULONG_MAX 4294967295 // 2<sup>32</sup> - 1</pre>
<!--page 35 -->
<li> minimum value for an object of type long long int
- LLONG_MIN -9223372036854775807 // -(263 - 1)
+<pre> LLONG_MIN -9223372036854775807 // -(2<sup>63</sup> - 1)</pre>
<li> maximum value for an object of type long long int
- LLONG_MAX +9223372036854775807 // 263 - 1
+<pre> LLONG_MAX +9223372036854775807 // 2<sup>63</sup> - 1</pre>
<li> maximum value for an object of type unsigned long long int
- ULLONG_MAX 18446744073709551615 // 264 - 1
+<pre> ULLONG_MAX 18446744073709551615 // 2<sup>64</sup> - 1</pre>
</ul>
<p><!--para 2 -->
If the value of an object of type char is treated as a signed integer when used in an
expression, the value of CHAR_MIN shall be the same as that of SCHAR_MIN and the
value of CHAR_MAX shall be the same as that of SCHAR_MAX. Otherwise, the value of
CHAR_MIN shall be 0 and the value of CHAR_MAX shall be the same as that of
- UCHAR_MAX.<sup><a href="#note15"><b>15)</b></a></sup> The value UCHAR_MAX shall equal 2CHAR_BIT - 1.
+ UCHAR_MAX.<sup><a href="#note15"><b>15)</b></a></sup> The value UCHAR_MAX shall equal 2<sup>CHAR_BIT</sup> - 1.
<p><b> Forward references</b>: representations of types (<a href="#6.2.6">6.2.6</a>), conditional inclusion (<a href="#6.10.1">6.10.1</a>).
<h6>footnotes</h6>
<p><small><a name="note15" href="#note15">15)</a> See <a href="#6.2.5">6.2.5</a>.
</small>
-<a name="5.2.4.2.2" href="#5.2.4.2.2"><h5>5.2.4.2.2 Characteristics of floating types <float.h></h5></a>
+<h5><a name="5.2.4.2.2" href="#5.2.4.2.2">5.2.4.2.2 Characteristics of floating types <float.h></a></h5>
<p><!--para 1 -->
The characteristics of floating types are defined in terms of a model that describes a
representation of floating-point numbers and values that provide information about an
b base or radix of exponent representation (an integer > 1)
e exponent (an integer between a minimum emin and a maximum emax )
p precision (the number of base-b digits in the significand)
- fk nonnegative integers less than b (the significand digits)</pre>
+ f<sub>k</sub> nonnegative integers less than b (the significand digits)</pre>
A floating-point number (x) is defined by the following model:
<pre>
p
- x = sb e (Sum) f k b-k ,
- k=1
- emin <= e <= emax</pre>
+ x = s b<sup>e</sup> (Sum) f<sub>k</sub> b<sup>-k</sup> , emin <= e <= emax
+ k=1</pre>
<p><!--para 3 -->
- In addition to normalized floating-point numbers ( f 1 > 0 if x != 0), floating types may be
+ In addition to normalized floating-point numbers ( f<sub>1</sub> > 0 if x != 0), floating types may be
able to contain other kinds of floating-point numbers, such as subnormal floating-point
- numbers (x != 0, e = emin , f 1 = 0) and unnormalized floating-point numbers (x != 0,
- e > emin , f 1 = 0), and values that are not floating-point numbers, such as infinities and
+ numbers (x != 0, e = emin , f<sub>1</sub> = 0) and unnormalized floating-point numbers (x != 0,
+ e > emin , f<sub>1</sub> = 0), and values that are not floating-point numbers, such as infinities and
NaNs. A NaN is an encoding signifying Not-a-Number. A quiet NaN propagates
through almost every arithmetic operation without raising a floating-point exception; a
signaling NaN generally raises a floating-point exception when occurring as an
All integer values in the <a href="#7.7"><float.h></a> header, except FLT_ROUNDS, shall be constant
expressions suitable for use in #if preprocessing directives; all floating values shall be
constant expressions. All except DECIMAL_DIG, FLT_EVAL_METHOD, FLT_RADIX,
- and FLT_ROUNDS have separate names for all three floating-point types. The floating-
- point model representation is provided for all values except FLT_EVAL_METHOD and
+ and FLT_ROUNDS have separate names for all three floating-point types. The floating-point
+ model representation is provided for all values except FLT_EVAL_METHOD and
FLT_ROUNDS.
<p><!--para 7 -->
The rounding mode for floating-point addition is characterized by the implementation-
those shown, with the same sign:
<ul>
<li> radix of exponent representation, b
- FLT_RADIX 2
+<pre> FLT_RADIX 2</pre>
<li> number of base-FLT_RADIX digits in the floating-point significand, p
- FLT_MANT_DIG
+<pre> FLT_MANT_DIG
DBL_MANT_DIG
- LDBL_MANT_DIG
+ LDBL_MANT_DIG</pre>
<li> number of decimal digits, n, such that any floating-point number in the widest
supported floating type with pmax radix b digits can be rounded to a floating-point
number with n decimal digits and back again without change to the value,
<pre>
- ??? pmax log10 b if b is a power of 10
- ???
- ??? ???1 + pmax log10 b??? otherwise</pre>
- DECIMAL_DIG 10
+ { pmax log10 b if b is a power of 10
+ {
+ { [^1 + pmax log10 b^] otherwise</pre>
+<pre> DECIMAL_DIG 10</pre>
<li> number of decimal digits, q, such that any floating-point number with q decimal digits
can be rounded into a floating-point number with p radix b digits and back again
without change to the q decimal digits,
<!--page 38 -->
<pre>
- ??? p log10 b if b is a power of 10
- ???
- ??? ???( p - 1) log10 b??? otherwise</pre>
- FLT_DIG 6
+ { p log10 b if b is a power of 10
+ {
+ { [_( p - 1) log10 b_] otherwise</pre>
+<pre> FLT_DIG 6
DBL_DIG 10
- LDBL_DIG 10
+ LDBL_DIG 10</pre>
<li> minimum negative integer such that FLT_RADIX raised to one less than that power is
a normalized floating-point number, emin
- FLT_MIN_EXP
+<pre> FLT_MIN_EXP
DBL_MIN_EXP
- LDBL_MIN_EXP
+ LDBL_MIN_EXP</pre>
<li> minimum negative integer such that 10 raised to that power is in the range of
- normalized floating-point numbers, ???log10 b emin -1 ???
-<pre>
- ??? ???</pre>
- FLT_MIN_10_EXP -37
+ normalized floating-point numbers, [^log10 b<sup>emin -1</sup>^]
+<pre> FLT_MIN_10_EXP -37
DBL_MIN_10_EXP -37
- LDBL_MIN_10_EXP -37
+ LDBL_MIN_10_EXP -37</pre>
<li> maximum integer such that FLT_RADIX raised to one less than that power is a
representable finite floating-point number, emax
- FLT_MAX_EXP
+<pre> FLT_MAX_EXP
DBL_MAX_EXP
- LDBL_MAX_EXP
+ LDBL_MAX_EXP</pre>
<li> maximum integer such that 10 raised to that power is in the range of representable
- finite floating-point numbers, ???log10 ((1 - b- p )b emax )???
- FLT_MAX_10_EXP +37
+ finite floating-point numbers, [_log10 ((1 - b<sup>-p</sup>)b<sup>emax</sup>)_]
+<pre> FLT_MAX_10_EXP +37
DBL_MAX_10_EXP +37
- LDBL_MAX_10_EXP +37
+ LDBL_MAX_10_EXP +37</pre>
</ul>
<p><!--para 10 -->
The values given in the following list shall be replaced by constant expressions with
implementation-defined values that are greater than or equal to those shown:
<ul>
-<li> maximum representable finite floating-point number, (1 - b- p )b emax
- FLT_MAX 1E+37
+<li> maximum representable finite floating-point number, (1 - b<sup>-p</sup>)b<sup>emax</sup>
+<pre> FLT_MAX 1E+37
DBL_MAX 1E+37
- LDBL_MAX 1E+37
+ LDBL_MAX 1E+37</pre>
</ul>
<p><!--para 11 -->
The values given in the following list shall be replaced by constant expressions with
implementation-defined (positive) values that are less than or equal to those shown:
<ul>
<li> the difference between 1 and the least value greater than 1 that is representable in the
- given floating point type, b1- p
+ given floating point type, b<sup>1-p</sup>
<!--page 39 -->
- FLT_EPSILON 1E-5
+<pre> FLT_EPSILON 1E-5
DBL_EPSILON 1E-9
- LDBL_EPSILON 1E-9
-<li> minimum normalized positive floating-point number, b emin -1
- FLT_MIN 1E-37
+ LDBL_EPSILON 1E-9</pre>
+<li> minimum normalized positive floating-point number, b<sup>emin -1</sup>
+<pre> FLT_MIN 1E-37
DBL_MIN 1E-37
- LDBL_MIN 1E-37
+ LDBL_MIN 1E-37</pre>
</ul>
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 12 -->
Conversion from (at least) double to decimal with DECIMAL_DIG digits and back
should be the identity function.
float:
<pre>
6
- x = s16e (Sum) f k 16-k ,
- k=1
- -31 <= e <= +32</pre>
+ x = s 16<sup>e</sup> (Sum) f<sub>k</sub> 16<sup>-k</sup> , -31 <= e <= +32
+ k=1</pre>
<pre>
FLT_RADIX 16
<a href="#7.7"><float.h></a> header for types float and double:
<pre>
24
- x f = s2e (Sum) f k 2-k ,
- k=1
- -125 <= e <= +128</pre>
+ xf = s 2<sup>e</sup> (Sum) f<sub>k</sub> 2<sup>-k</sup> , -125 <= e <= +128
+ k=1</pre>
<pre>
53
- x d = s2e (Sum) f k 2-k ,
- k=1
- -1021 <= e <= +1024</pre>
+ xd = s 2<sup>e</sup> (Sum) f<sub>k</sub> 2<sup>-k</sup> , -1021 <= e <= +1024
+ k=1</pre>
+
<pre>
FLT_RADIX 2
limits are one less than shown here.
</small>
-<a name="6" href="#6"><h2>6. Language</h2></a>
+<h2><a name="6" href="#6">6. Language</a></h2>
-<a name="6.1" href="#6.1"><h3>6.1 Notation</h3></a>
+<h3><a name="6.1" href="#6.1">6.1 Notation</a></h3>
<p><!--para 1 -->
In the syntax notation used in this clause, syntactic categories (nonterminals) are
indicated by italic type, and literal words and character set members (terminals) by bold
definitions are listed on separate lines, except when prefaced by the words ''one of''. An
optional symbol is indicated by the subscript ''opt'', so that
<pre>
- { expressionopt }</pre>
+ { expression<sub>opt</sub> }</pre>
indicates an optional expression enclosed in braces.
<p><!--para 2 -->
When syntactic categories are referred to in the main text, they are not italicized and
<p><!--para 3 -->
A summary of the language syntax is given in <a href="#A">annex A</a>.
-<a name="6.2" href="#6.2"><h3>6.2 Concepts</h3></a>
+<h3><a name="6.2" href="#6.2">6.2 Concepts</a></h3>
-<a name="6.2.1" href="#6.2.1"><h4>6.2.1 Scopes of identifiers</h4></a>
+<h4><a name="6.2.1" href="#6.2.1">6.2.1 Scopes of identifiers</a></h4>
<p><!--para 1 -->
An identifier can denote an object; a function; a tag or a member of a structure, union, or
enumeration; a typedef name; a label name; a macro name; or a macro parameter. The
(<a href="#6.9.1">6.9.1</a>), identifiers (<a href="#6.4.2">6.4.2</a>), name spaces of identifiers (<a href="#6.2.3">6.2.3</a>), macro replacement (<a href="#6.10.3">6.10.3</a>),
source file inclusion (<a href="#6.10.2">6.10.2</a>), statements (<a href="#6.8">6.8</a>).
-<a name="6.2.2" href="#6.2.2"><h4>6.2.2 Linkages of identifiers</h4></a>
+<h4><a name="6.2.2" href="#6.2.2">6.2.2 Linkages of identifiers</a></h4>
<p><!--para 1 -->
An identifier declared in different scopes or in the same scope more than once can be
made to refer to the same object or function by a process called linkage.<sup><a href="#note21"><b>21)</b></a></sup> There are
<p><small><a name="note23" href="#note23">23)</a> As specified in <a href="#6.2.1">6.2.1</a>, the later declaration might hide the prior declaration.
</small>
-<a name="6.2.3" href="#6.2.3"><h4>6.2.3 Name spaces of identifiers</h4></a>
+<h4><a name="6.2.3" href="#6.2.3">6.2.3 Name spaces of identifiers</a></h4>
<p><!--para 1 -->
If more than one declaration of a particular identifier is visible at any point in a
translation unit, the syntactic context disambiguates uses that refer to different entities.
<p><small><a name="note24" href="#note24">24)</a> There is only one name space for tags even though three are possible.
</small>
-<a name="6.2.4" href="#6.2.4"><h4>6.2.4 Storage durations of objects</h4></a>
+<h4><a name="6.2.4" href="#6.2.4">6.2.4 Storage durations of objects</a></h4>
<p><!--para 1 -->
An object has a storage duration that determines its lifetime. There are three storage
durations: static, automatic, and allocated. Allocated storage is described in <a href="#7.20.3">7.20.3</a>.
embedded block prior to the declaration, leaves the scope of the declaration.
</small>
-<a name="6.2.5" href="#6.2.5"><h4>6.2.5 Types</h4></a>
+<h4><a name="6.2.5" href="#6.2.5">6.2.5 Types</a></h4>
<p><!--para 1 -->
The meaning of a value stored in an object or returned by a function is determined by the
type of the expression used to access it. (An identifier declared to be an object is the
arguments to functions, return values from functions, and members of unions.
</small>
-<a name="6.2.6" href="#6.2.6"><h4>6.2.6 Representations of types</h4></a>
+<h4><a name="6.2.6" href="#6.2.6">6.2.6 Representations of types</a></h4>
-<a name="6.2.6.1" href="#6.2.6.1"><h5>6.2.6.1 General</h5></a>
+<h5><a name="6.2.6.1" href="#6.2.6.1">6.2.6.1 General</a></h5>
<p><!--para 1 -->
The representations of all types are unspecified except as stated in this subclause.
<p><!--para 2 -->
represented by successive bits are additive, begin with 1, and are multiplied by successive integral
powers of 2, except perhaps the bit with the highest position. (Adapted from the American National
Dictionary for Information Processing Systems.) A byte contains CHAR_BIT bits, and the values of
- type unsigned char range from 0 to 2
-
-<pre>
- CHAR_BIT
- - 1.</pre>
+ type unsigned char range from 0 to 2<sup>CHAR_BIT</sup>- 1.
</small>
<p><small><a name="note41" href="#note41">41)</a> Thus, an automatic variable can be initialized to a trap representation without causing undefined
behavior, but the value of the variable cannot be used until a proper value is stored in it.
on values of type T may distinguish between them.
</small>
-<a name="6.2.6.2" href="#6.2.6.2"><h5>6.2.6.2 Integer types</h5></a>
+<h5><a name="6.2.6.2" href="#6.2.6.2">6.2.6.2 Integer types</a></h5>
<p><!--para 1 -->
For unsigned integer types other than unsigned char, the bits of the object
representation shall be divided into two groups: value bits and padding bits (there need
not be any of the latter). If there are N value bits, each bit shall represent a different
- power of 2 between 1 and 2 N -1 , so that objects of that type shall be capable of
- representing values from 0 to 2 N - 1 using a pure binary representation; this shall be
+ power of 2 between 1 and 2<sup>N-1</sup> , so that objects of that type shall be capable of
+ representing values from 0 to 2<sup>N</sup> - 1 using a pure binary representation; this shall be
known as the value representation. The values of any padding bits are unspecified.<sup><a href="#note44"><b>44)</b></a></sup>
<p><!--para 2 -->
For signed integer types, the bits of the object representation shall be divided into three
modified in one of the following ways:
<ul>
<li> the corresponding value with sign bit 0 is negated (sign and magnitude);
-<li> the sign bit has the value -(2 N ) (two's complement);
-<li> the sign bit has the value -(2 N - 1) (ones' complement ).
+<li> the sign bit has the value -(2<sup>N</sup> ) (two's complement);
+<li> the sign bit has the value -(2<sup>N</sup> - 1) (ones' complement ).
</ul>
Which of these applies is implementation-defined, as is whether the value with sign bit 1
and all value bits zero (for the first two), or with sign bit and all value bits 1 (for ones'
bits.
</small>
-<a name="6.2.7" href="#6.2.7"><h4>6.2.7 Compatible type and composite type</h4></a>
+<h4><a name="6.2.7" href="#6.2.7">6.2.7 Compatible type and composite type</a></h4>
<p><!--para 1 -->
Two types have compatible type if their types are the same. Additional rules for
determining whether two types are compatible are described in <a href="#6.7.2">6.7.2</a> for type specifiers,
<p><small><a name="note47" href="#note47">47)</a> As specified in <a href="#6.2.1">6.2.1</a>, the later declaration might hide the prior declaration.
</small>
-<a name="6.3" href="#6.3"><h3>6.3 Conversions</h3></a>
+<h3><a name="6.3" href="#6.3">6.3 Conversions</a></h3>
<p><!--para 1 -->
Several operators convert operand values from one type to another automatically. This
subclause specifies the result required from such an implicit conversion, as well as those
representation.
<p><b> Forward references</b>: cast operators (<a href="#6.5.4">6.5.4</a>).
-<a name="6.3.1" href="#6.3.1"><h4>6.3.1 Arithmetic operands</h4></a>
+<h4><a name="6.3.1" href="#6.3.1">6.3.1 Arithmetic operands</a></h4>
-<a name="6.3.1.1" href="#6.3.1.1"><h5>6.3.1.1 Boolean, characters, and integers</h5></a>
+<h5><a name="6.3.1.1" href="#6.3.1.1">6.3.1.1 Boolean, characters, and integers</a></h5>
<p><!--para 1 -->
Every integer type has an integer conversion rank defined as follows:
<ul>
shift operators, as specified by their respective subclauses.
</small>
-<a name="6.3.1.2" href="#6.3.1.2"><h5>6.3.1.2 Boolean type</h5></a>
+<h5><a name="6.3.1.2" href="#6.3.1.2">6.3.1.2 Boolean type</a></h5>
<p><!--para 1 -->
When any scalar value is converted to _Bool, the result is 0 if the value compares equal
to 0; otherwise, the result is 1.
-<a name="6.3.1.3" href="#6.3.1.3"><h5>6.3.1.3 Signed and unsigned integers</h5></a>
+<h5><a name="6.3.1.3" href="#6.3.1.3">6.3.1.3 Signed and unsigned integers</a></h5>
<p><!--para 1 -->
When a value with integer type is converted to another integer type other than _Bool, if
the value can be represented by the new type, it is unchanged.
<p><small><a name="note49" href="#note49">49)</a> The rules describe arithmetic on the mathematical value, not the value of a given type of expression.
</small>
-<a name="6.3.1.4" href="#6.3.1.4"><h5>6.3.1.4 Real floating and integer</h5></a>
+<h5><a name="6.3.1.4" href="#6.3.1.4">6.3.1.4 Real floating and integer</a></h5>
<p><!--para 1 -->
When a finite value of real floating type is converted to an integer type other than _Bool,
the fractional part is discarded (i.e., the value is truncated toward zero). If the value of
range of portable real floating values is (-1, Utype_MAX+1).
</small>
-<a name="6.3.1.5" href="#6.3.1.5"><h5>6.3.1.5 Real floating types</h5></a>
+<h5><a name="6.3.1.5" href="#6.3.1.5">6.3.1.5 Real floating types</a></h5>
<p><!--para 1 -->
When a float is promoted to double or long double, or a double is promoted
to long double, its value is unchanged (if the source value is represented in the
value, chosen in an implementation-defined manner. If the value being converted is
outside the range of values that can be represented, the behavior is undefined.
-<a name="6.3.1.6" href="#6.3.1.6"><h5>6.3.1.6 Complex types</h5></a>
+<h5><a name="6.3.1.6" href="#6.3.1.6">6.3.1.6 Complex types</a></h5>
<p><!--para 1 -->
When a value of complex type is converted to another complex type, both the real and
imaginary parts follow the conversion rules for the corresponding real types.
-<a name="6.3.1.7" href="#6.3.1.7"><h5>6.3.1.7 Real and complex</h5></a>
+<h5><a name="6.3.1.7" href="#6.3.1.7">6.3.1.7 Real and complex</a></h5>
<p><!--para 1 -->
When a value of real type is converted to a complex type, the real part of the complex
result value is determined by the rules of conversion to the corresponding real type and
complex value is discarded and the value of the real part is converted according to the
conversion rules for the corresponding real type.
-<a name="6.3.1.8" href="#6.3.1.8"><h5>6.3.1.8 Usual arithmetic conversions</h5></a>
+<h5><a name="6.3.1.8" href="#6.3.1.8">6.3.1.8 Usual arithmetic conversions</a></h5>
<p><!--para 1 -->
Many operators that expect operands of arithmetic type cause conversions and yield result
types in a similar way. The purpose is to determine a common real type for the operands
and complex otherwise. This pattern is called the usual arithmetic conversions:
<!--page 57 -->
<p><!--para 2 -->
-<pre>
- First, if the corresponding real type of either operand is long double, the other
+<ul>
+<li> First, if the corresponding real type of either operand is long double, the other
operand is converted, without change of type domain, to a type whose
corresponding real type is long double.
- Otherwise, if the corresponding real type of either operand is double, the other
+<li> Otherwise, if the corresponding real type of either operand is double, the other
operand is converted, without change of type domain, to a type whose
corresponding real type is double.
- Otherwise, if the corresponding real type of either operand is float, the other
+<li> Otherwise, if the corresponding real type of either operand is float, the other
operand is converted, without change of type domain, to a type whose
corresponding real type is float.<sup><a href="#note51"><b>51)</b></a></sup>
- Otherwise, the integer promotions are performed on both operands. Then the
+<li> Otherwise, the integer promotions are performed on both operands. Then the
following rules are applied to the promoted operands:
- If both operands have the same type, then no further conversion is needed.
- Otherwise, if both operands have signed integer types or both have unsigned
+<ul>
+<li> If both operands have the same type, then no further conversion is needed.
+<li> Otherwise, if both operands have signed integer types or both have unsigned
integer types, the operand with the type of lesser integer conversion rank is
converted to the type of the operand with greater rank.
- Otherwise, if the operand that has unsigned integer type has rank greater or
+<li> Otherwise, if the operand that has unsigned integer type has rank greater or
equal to the rank of the type of the other operand, then the operand with
signed integer type is converted to the type of the operand with unsigned
integer type.
- Otherwise, if the type of the operand with signed integer type can represent
+<li> Otherwise, if the type of the operand with signed integer type can represent
all of the values of the type of the operand with unsigned integer type, then
the operand with unsigned integer type is converted to the type of the
operand with signed integer type.
- Otherwise, both operands are converted to the unsigned integer type
- corresponding to the type of the operand with signed integer type.</pre>
+<li> Otherwise, both operands are converted to the unsigned integer type
+ corresponding to the type of the operand with signed integer type.
+</ul>
+</ul>
The values of floating operands and of the results of floating expressions may be
represented in greater precision and range than that required by the type; the types are not
changed thereby.<sup><a href="#note52"><b>52)</b></a></sup>
described in <a href="#6.3.1.4">6.3.1.4</a> and <a href="#6.3.1.5">6.3.1.5</a>.
</small>
-<a name="6.3.2" href="#6.3.2"><h4>6.3.2 Other operands</h4></a>
+<h4><a name="6.3.2" href="#6.3.2">6.3.2 Other operands</a></h4>
-<a name="6.3.2.1" href="#6.3.2.1"><h5>6.3.2.1 Lvalues, arrays, and function designators</h5></a>
+<h5><a name="6.3.2.1" href="#6.3.2.1">6.3.2.1 Lvalues, arrays, and function designators</a></h5>
<p><!--para 1 -->
An lvalue is an expression with an object type or an incomplete type other than void;<sup><a href="#note53"><b>53)</b></a></sup>
if an lvalue does not designate an object when it is evaluated, the behavior is undefined.
designator and violates the constraint in <a href="#6.5.3.4">6.5.3.4</a>.
</small>
-<a name="6.3.2.2" href="#6.3.2.2"><h5>6.3.2.2 void</h5></a>
+<h5><a name="6.3.2.2" href="#6.3.2.2">6.3.2.2 void</a></h5>
<p><!--para 1 -->
The (nonexistent) value of a void expression (an expression that has type void) shall not
be used in any way, and implicit or explicit conversions (except to void) shall not be
expression, its value or designator is discarded. (A void expression is evaluated for its
side effects.)
-<a name="6.3.2.3" href="#6.3.2.3"><h5>6.3.2.3 Pointers</h5></a>
+<h5><a name="6.3.2.3" href="#6.3.2.3">6.3.2.3 Pointers</a></h5>
<p><!--para 1 -->
A pointer to void may be converted to or from a pointer to any incomplete or object
type. A pointer to any incomplete or object type may be converted to a pointer to void
correctly aligned for a pointer to type C.
</small>
-<a name="6.4" href="#6.4"><h3>6.4 Lexical elements</h3></a>
+<h3><a name="6.4" href="#6.4">6.4 Lexical elements</a></h3>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
occur in source files.
</small>
-<a name="6.4.1" href="#6.4.1"><h4>6.4.1 Keywords</h4></a>
+<h4><a name="6.4.1" href="#6.4.1">6.4.1 Keywords</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note59" href="#note59">59)</a> One possible specification for imaginary types appears in <a href="#G">annex G</a>.
</small>
-<a name="6.4.2" href="#6.4.2"><h4>6.4.2 Identifiers</h4></a>
+<h4><a name="6.4.2" href="#6.4.2">6.4.2 Identifiers</a></h4>
-<a name="6.4.2.1" href="#6.4.2.1"><h5>6.4.2.1 General</h5></a>
+<h5><a name="6.4.2.1" href="#6.4.2.1">6.4.2.1 General</a></h5>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<!--page 64 -->
- Implementation limits
+<h6> Implementation limits</h6>
<p><!--para 5 -->
As discussed in <a href="#5.2.4.1">5.2.4.1</a>, an implementation may limit the number of significant initial
characters in an identifier; the limit for an external name (an identifier that has external
Extended characters may produce a long external identifier.
</small>
-<a name="6.4.2.2" href="#6.4.2.2"><h5>6.4.2.2 Predefined identifiers</h5></a>
+<h5><a name="6.4.2.2" href="#6.4.2.2">6.4.2.2 Predefined identifiers</a></h5>
<h6>Semantics</h6>
<p><!--para 1 -->
The identifier __func__ shall be implicitly declared by the translator as if,
identifier is explicitly declared using the name __func__, the behavior is undefined.
</small>
-<a name="6.4.3" href="#6.4.3"><h4>6.4.3 Universal character names</h4></a>
+<h4><a name="6.4.3" href="#6.4.3">6.4.3 Universal character names</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note63" href="#note63">63)</a> Short identifiers for characters were first specified in ISO/IEC 10646-1/AMD9:1997.
</small>
-<a name="6.4.4" href="#6.4.4"><h4>6.4.4 Constants</h4></a>
+<h4><a name="6.4.4" href="#6.4.4">6.4.4 Constants</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
Each constant has a type, determined by its form and value, as detailed later.
-<a name="6.4.4.1" href="#6.4.4.1"><h5>6.4.4.1 Integer constants</h5></a>
+<h5><a name="6.4.4.1" href="#6.4.4.1">6.4.4.1 Integer constants</a></h5>
<h6>Syntax</h6>
<p><!--para 1 -->
<!--page 67 -->
<pre>
integer-constant:
- decimal-constant integer-suffixopt
- octal-constant integer-suffixopt
- hexadecimal-constant integer-suffixopt
+ decimal-constant integer-suffix<sub>opt</sub>
+ octal-constant integer-suffix<sub>opt</sub>
+ hexadecimal-constant integer-suffix<sub>opt</sub>
decimal-constant:
nonzero-digit
decimal-constant digit
a b c d e f
A B C D E F
integer-suffix:
- unsigned-suffix long-suffixopt
+ unsigned-suffix long-suffix<sub>opt</sub>
unsigned-suffix long-long-suffix
- long-suffix unsigned-suffixopt
- long-long-suffix unsigned-suffixopt
+ long-suffix unsigned-suffix<sub>opt</sub>
+ long-long-suffix unsigned-suffix<sub>opt</sub>
unsigned-suffix: one of
u U
long-suffix: one of
The type of an integer constant is the first of the corresponding list in which its value can
be represented.
<!--page 68 -->
-<pre>
- Octal or Hexadecimal</pre>
- Suffix Decimal Constant Constant
-
- none int int
-<pre>
- long int unsigned int
- long long int long int
- unsigned long int
- long long int
- unsigned long long int</pre>
-
- u or U unsigned int unsigned int
-<pre>
- unsigned long int unsigned long int
- unsigned long long int unsigned long long int</pre>
-
- l or L long int long int
-<pre>
- long long int unsigned long int
- long long int
- unsigned long long int</pre>
-
- Both u or U unsigned long int unsigned long int
- and l or L unsigned long long int unsigned long long int
-
- ll or LL long long int long long int
-<pre>
- unsigned long long int</pre>
-
- Both u or U unsigned long long int unsigned long long int
- and ll or LL
+<table border=1>
+<tr><th> Suffix <th>Decimal Constant <th>Octal or Hexadecimal Constant
+<tr><td> none
+<td><pre>int
+long int
+long long int</pre>
+<td><pre>int
+unsigned int
+long int
+unsigned long int
+long long int
+unsigned long long int</pre>
+<tr><td> u or U
+<td><pre>unsigned int
+unsigned long int
+unsigned long long int</pre>
+<td><pre>unsigned int
+unsigned long int
+unsigned long long int</pre>
+<tr><td> l or L
+<td><pre>long int
+long long int</pre>
+<td><pre>long int
+unsigned long int
+long long int
+unsigned long long int</pre>
+<tr><td> Both u or U and l or L
+<td><pre>unsigned long int
+unsigned long long int</pre>
+<td><pre>unsigned long int
+unsigned long long int</pre>
+<tr><td> ll or LL
+<td><pre>long long int</pre>
+<td><pre>long long int
+unsigned long long int</pre>
+<tr><td> Both u or U and ll or LL
+<td><pre>unsigned long long int</pre>
+<td><pre>unsigned long long int</pre>
+</table>
<p><!--para 6 -->
If an integer constant cannot be represented by any type in its list, it may have an
extended integer type, if the extended integer type can represent its value. If all of the
its list and has no extended integer type, then the integer constant has no type.
<!--page 69 -->
-<a name="6.4.4.2" href="#6.4.4.2"><h5>6.4.4.2 Floating constants</h5></a>
+<h5><a name="6.4.4.2" href="#6.4.4.2">6.4.4.2 Floating constants</a></h5>
<h6>Syntax</h6>
<p><!--para 1 -->
<!--page 70 -->
decimal-floating-constant
hexadecimal-floating-constant
decimal-floating-constant:
- fractional-constant exponent-partopt floating-suffixopt
- digit-sequence exponent-part floating-suffixopt
+ fractional-constant exponent-part<sub>opt</sub> floating-suffix<sub>opt</sub>
+ digit-sequence exponent-part floating-suffix<sub>opt</sub>
hexadecimal-floating-constant:
hexadecimal-prefix hexadecimal-fractional-constant
- binary-exponent-part floating-suffixopt
+ binary-exponent-part floating-suffix<sub>opt</sub>
hexadecimal-prefix hexadecimal-digit-sequence
- binary-exponent-part floating-suffixopt
+ binary-exponent-part floating-suffix<sub>opt</sub>
fractional-constant:
- digit-sequenceopt . digit-sequence
+ digit-sequence<sub>opt</sub> . digit-sequence
digit-sequence .
exponent-part:
- e signopt digit-sequence
- E signopt digit-sequence
+ e sign<sub>opt</sub> digit-sequence
+ E sign<sub>opt</sub> digit-sequence
sign: one of
+ -
digit-sequence:
digit
digit-sequence digit
hexadecimal-fractional-constant:
- hexadecimal-digit-sequenceopt .
+ hexadecimal-digit-sequence<sub>opt</sub> .
hexadecimal-digit-sequence
hexadecimal-digit-sequence .
binary-exponent-part:
- p signopt digit-sequence
- P signopt digit-sequence
+ p sign<sub>opt</sub> digit-sequence
+ P sign<sub>opt</sub> digit-sequence
hexadecimal-digit-sequence:
hexadecimal-digit
hexadecimal-digit-sequence hexadecimal-digit
Floating constants are converted to internal format as if at translation-time. The
conversion of a floating constant shall not raise an exceptional condition or a floating-
point exception at execution time.
- Recommended practice
+<h6>Recommended practice</h6>
<p><!--para 6 -->
The implementation should produce a diagnostic message if a hexadecimal constant
cannot be represented exactly in its evaluation format; the implementation should then
floating constants (see <a href="#7.20.1.3">7.20.1.3</a>).
</small>
-<a name="6.4.4.3" href="#6.4.4.3"><h5>6.4.4.3 Enumeration constants</h5></a>
+<h5><a name="6.4.4.3" href="#6.4.4.3">6.4.4.3 Enumeration constants</a></h5>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
An identifier declared as an enumeration constant has type int.
<p><b> Forward references</b>: enumeration specifiers (<a href="#6.7.2.2">6.7.2.2</a>).
-<a name="6.4.4.4" href="#6.4.4.4"><h5>6.4.4.4 Character constants</h5></a>
+<h5><a name="6.4.4.4" href="#6.4.4.4">6.4.4.4 Character constants</a></h5>
<h6>Syntax</h6>
<p><!--para 1 -->
<!--page 72 -->
the result is not a token and a diagnostic is required. See ''future language directions'' (<a href="#6.11.4">6.11.4</a>).
</small>
-<a name="6.4.5" href="#6.4.5"><h4>6.4.5 String literals</h4></a>
+<h4><a name="6.4.5" href="#6.4.5">6.4.5 String literals</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
string-literal:
- " s-char-sequenceopt "
- L" s-char-sequenceopt "
+ " s-char-sequence<sub>opt</sub> "
+ L" s-char-sequence<sub>opt</sub> "
s-char-sequence:
s-char
s-char-sequence s-char
it by a \0 escape sequence.
</small>
-<a name="6.4.6" href="#6.4.6"><h4>6.4.6 Punctuators</h4></a>
+<h4><a name="6.4.6" href="#6.4.6">6.4.6 Punctuators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
interchanged.
</small>
-<a name="6.4.7" href="#6.4.7"><h4>6.4.7 Header names</h4></a>
+<h4><a name="6.4.7" href="#6.4.7">6.4.7 Header names</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note70" href="#note70">70)</a> For an example of a header name preprocessing token used in a #pragma directive, see <a href="#6.10.9">6.10.9</a>.
</small>
-<a name="6.4.8" href="#6.4.8"><h4>6.4.8 Preprocessing numbers</h4></a>
+<h4><a name="6.4.8" href="#6.4.8">6.4.8 Preprocessing numbers</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<!--page 78 -->
-<a name="6.4.9" href="#6.4.9"><h4>6.4.9 Comments</h4></a>
+<h4><a name="6.4.9" href="#6.4.9">6.4.9 Comments</a></h4>
<p><!--para 1 -->
Except within a character constant, a string literal, or a comment, the characters /*
introduce a comment. The contents of such a comment are examined only to identify
<p><small><a name="note71" href="#note71">71)</a> Thus, /* ... */ comments do not nest.
</small>
-<a name="6.5" href="#6.5"><h3>6.5 Expressions</h3></a>
+<h3><a name="6.5" href="#6.5">6.5 Expressions</a></h3>
<p><!--para 1 -->
An expression is a sequence of operators and operands that specifies computation of a
value, or that designates an object or a function, or that generates side effects, or that
<pre>
i = ++i + 1;
- a[i++] = i;
+ a[i++] = i;</pre>
while allowing
+<pre>
i = i + 1;
a[i] = i;</pre>
parentheses () (<a href="#6.5.1">6.5.1</a>), subscripting brackets [] (<a href="#6.5.2.1">6.5.2.1</a>), function-call parentheses () (<a href="#6.5.2.2">6.5.2.2</a>), and
the conditional operator ?: (<a href="#6.5.15">6.5.15</a>).
-<pre>
- Within each major subclause, the operators have the same precedence. Left- or right-associativity is
- indicated in each subclause by the syntax for the expressions discussed therein.</pre>
+ Within each major subclause, the operators have the same precedence. Left- or right-associativity is
+ indicated in each subclause by the syntax for the expressions discussed therein.
</small>
<p><small><a name="note75" href="#note75">75)</a> Allocated objects have no declared type.
</small>
documented.
</small>
-<a name="6.5.1" href="#6.5.1"><h4>6.5.1 Primary expressions</h4></a>
+<h4><a name="6.5.1" href="#6.5.1">6.5.1 Primary expressions</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note79" href="#note79">79)</a> Thus, an undeclared identifier is a violation of the syntax.
</small>
-<a name="6.5.2" href="#6.5.2"><h4>6.5.2 Postfix operators</h4></a>
+<h4><a name="6.5.2" href="#6.5.2">6.5.2 Postfix operators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
assignment-expression
argument-expression-list , assignment-expression</pre>
-<a name="6.5.2.1" href="#6.5.2.1"><h5>6.5.2.1 Array subscripting</h5></a>
+<h5><a name="6.5.2.1" href="#6.5.2.1">6.5.2.1 Array subscripting</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
One of the expressions shall have type ''pointer to object type'', the other expression shall
(<a href="#6.5.3.2">6.5.3.2</a>), array declarators (<a href="#6.7.5.2">6.7.5.2</a>).
<!--page 83 -->
-<a name="6.5.2.2" href="#6.5.2.2"><h5>6.5.2.2 Function calls</h5></a>
+<h5><a name="6.5.2.2" href="#6.5.2.2">6.5.2.2 Function calls</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The expression that denotes the called function<sup><a href="#note80"><b>80)</b></a></sup> shall have type pointer to function
adjusted to have a pointer type as described in <a href="#6.9.1">6.9.1</a>.
</small>
-<a name="6.5.2.3" href="#6.5.2.3"><h5>6.5.2.3 Structure and union members</h5></a>
+<h5><a name="6.5.2.3" href="#6.5.2.3">6.5.2.3 Structure and union members</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The first operand of the . operator shall have a qualified or unqualified structure or union
its operand), the expression (&E)->MOS is the same as E.MOS.
</small>
-<a name="6.5.2.4" href="#6.5.2.4"><h5>6.5.2.4 Postfix increment and decrement operators</h5></a>
+<h5><a name="6.5.2.4" href="#6.5.2.4">6.5.2.4 Postfix increment and decrement operators</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The operand of the postfix increment or decrement operator shall have qualified or
it).
<p><b> Forward references</b>: additive operators (<a href="#6.5.6">6.5.6</a>), compound assignment (<a href="#6.5.16.2">6.5.16.2</a>).
-<a name="6.5.2.5" href="#6.5.2.5"><h5>6.5.2.5 Compound literals</h5></a>
+<h5><a name="6.5.2.5" href="#6.5.2.5">6.5.2.5 Compound literals</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The type name shall specify an object type or an array of unknown size, but not a variable
the same or overlapping representations.
</small>
-<a name="6.5.3" href="#6.5.3"><h4>6.5.3 Unary operators</h4></a>
+<h4><a name="6.5.3" href="#6.5.3">6.5.3 Unary operators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
unary-operator: one of
& * + - ~ !</pre>
-<a name="6.5.3.1" href="#6.5.3.1"><h5>6.5.3.1 Prefix increment and decrement operators</h5></a>
+<h5><a name="6.5.3.1" href="#6.5.3.1">6.5.3.1 Prefix increment and decrement operators</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The operand of the prefix increment or decrement operator shall have qualified or
operand is decremented.
<p><b> Forward references</b>: additive operators (<a href="#6.5.6">6.5.6</a>), compound assignment (<a href="#6.5.16.2">6.5.16.2</a>).
-<a name="6.5.3.2" href="#6.5.3.2"><h5>6.5.3.2 Address and indirection operators</h5></a>
+<h5><a name="6.5.3.2" href="#6.5.3.2">6.5.3.2 Address and indirection operators</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The operand of the unary & operator shall be either a function designator, the result of a
end of its lifetime.
</small>
-<a name="6.5.3.3" href="#6.5.3.3"><h5>6.5.3.3 Unary arithmetic operators</h5></a>
+<h5><a name="6.5.3.3" href="#6.5.3.3">6.5.3.3 Unary arithmetic operators</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The operand of the unary + or - operator shall have arithmetic type; of the ~ operator,
<!--page 92 -->
-<a name="6.5.3.4" href="#6.5.3.4"><h5>6.5.3.4 The sizeof operator</h5></a>
+<h5><a name="6.5.3.4" href="#6.5.3.4">6.5.3.4 The sizeof operator</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The sizeof operator shall not be applied to an expression that has function type or an
size of the adjusted (pointer) type (see <a href="#6.9.1">6.9.1</a>).
</small>
-<a name="6.5.4" href="#6.5.4"><h4>6.5.4 Cast operators</h4></a>
+<h4><a name="6.5.4" href="#6.5.4">6.5.4 Cast operators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
unqualified version of the type.
</small>
-<a name="6.5.5" href="#6.5.5"><h4>6.5.5 Multiplicative operators</h4></a>
+<h4><a name="6.5.5" href="#6.5.5">6.5.5 Multiplicative operators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note90" href="#note90">90)</a> This is often called ''truncation toward zero''.
</small>
-<a name="6.5.6" href="#6.5.6"><h4>6.5.6 Additive operators</h4></a>
+<h4><a name="6.5.6" href="#6.5.6">6.5.6 Additive operators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
element'' requirements.
</small>
-<a name="6.5.7" href="#6.5.7"><h4>6.5.7 Bitwise shift operators</h4></a>
+<h4><a name="6.5.7" href="#6.5.7">6.5.7 Bitwise shift operators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
part of the quotient of E1 / 2E2 . If E1 has a signed type and a negative value, the
resulting value is implementation-defined.
-<a name="6.5.8" href="#6.5.8"><h4>6.5.8 Relational operators</h4></a>
+<h4><a name="6.5.8" href="#6.5.8">6.5.8 Relational operators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
means (a<b)<c; in other words, ''if a is less than b, compare 1 to c; otherwise, compare 0 to c''.
</small>
-<a name="6.5.9" href="#6.5.9"><h4>6.5.9 Equality operators</h4></a>
+<h4><a name="6.5.9" href="#6.5.9">6.5.9 Equality operators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
behavior.
</small>
-<a name="6.5.10" href="#6.5.10"><h4>6.5.10 Bitwise AND operator</h4></a>
+<h4><a name="6.5.10" href="#6.5.10">6.5.10 Bitwise AND operator</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<!--page 100 -->
-<a name="6.5.11" href="#6.5.11"><h4>6.5.11 Bitwise exclusive OR operator</h4></a>
+<h4><a name="6.5.11" href="#6.5.11">6.5.11 Bitwise exclusive OR operator</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
in the result is set if and only if exactly one of the corresponding bits in the converted
operands is set).
-<a name="6.5.12" href="#6.5.12"><h4>6.5.12 Bitwise inclusive OR operator</h4></a>
+<h4><a name="6.5.12" href="#6.5.12">6.5.12 Bitwise inclusive OR operator</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
operands is set).
<!--page 101 -->
-<a name="6.5.13" href="#6.5.13"><h4>6.5.13 Logical AND operator</h4></a>
+<h4><a name="6.5.13" href="#6.5.13">6.5.13 Logical AND operator</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
there is a sequence point after the evaluation of the first operand. If the first operand
compares equal to 0, the second operand is not evaluated.
-<a name="6.5.14" href="#6.5.14"><h4>6.5.14 Logical OR operator</h4></a>
+<h4><a name="6.5.14" href="#6.5.14">6.5.14 Logical OR operator</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
unequal to 0, the second operand is not evaluated.
<!--page 102 -->
-<a name="6.5.15" href="#6.5.15"><h4>6.5.15 Conditional operator</h4></a>
+<h4><a name="6.5.15" href="#6.5.15">6.5.15 Conditional operator</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note95" href="#note95">95)</a> A conditional expression does not yield an lvalue.
</small>
-<a name="6.5.16" href="#6.5.16"><h4>6.5.16 Assignment operators</h4></a>
+<h4><a name="6.5.16" href="#6.5.16">6.5.16 Assignment operators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
behavior is undefined.
<!--page 104 -->
-<a name="6.5.16.1" href="#6.5.16.1"><h5>6.5.16.1 Simple assignment</h5></a>
+<h5><a name="6.5.16.1" href="#6.5.16.1">6.5.16.1 Simple assignment</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
One of the following shall hold:<sup><a href="#note96"><b>96)</b></a></sup>
not volatile from the type int volatile * const).
</small>
-<a name="6.5.16.2" href="#6.5.16.2"><h5>6.5.16.2 Compound assignment</h5></a>
+<h5><a name="6.5.16.2" href="#6.5.16.2">6.5.16.2 Compound assignment</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
For the operators += and -= only, either the left operand shall be a pointer to an object
expression E1 = E1 op (E2) only in that the lvalue E1 is evaluated only once.
<!--page 106 -->
-<a name="6.5.17" href="#6.5.17"><h4>6.5.17 Comma operator</h4></a>
+<h4><a name="6.5.17" href="#6.5.17">6.5.17 Comma operator</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note97" href="#note97">97)</a> A comma operator does not yield an lvalue.
</small>
-<a name="6.6" href="#6.6"><h3>6.6 Constant expressions</h3></a>
+<h3><a name="6.6" href="#6.6">6.6 Constant expressions</a></h3>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
the expression is a valid integer constant expression with value one.
</small>
-<a name="6.7" href="#6.7"><h3>6.7 Declarations</h3></a>
+<h3><a name="6.7" href="#6.7">6.7 Declarations</a></h3>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
declaration:
- declaration-specifiers init-declarator-listopt ;
+ declaration-specifiers init-declarator-list<sub>opt</sub> ;
declaration-specifiers:
- storage-class-specifier declaration-specifiersopt
- type-specifier declaration-specifiersopt
- type-qualifier declaration-specifiersopt
- function-specifier declaration-specifiersopt
+ storage-class-specifier declaration-specifiers<sub>opt</sub>
+ type-specifier declaration-specifiers<sub>opt</sub>
+ type-qualifier declaration-specifiers<sub>opt</sub>
+ function-specifier declaration-specifiers<sub>opt</sub>
init-declarator-list:
init-declarator
init-declarator-list , init-declarator
<p><small><a name="note101" href="#note101">101)</a> Function definitions have a different syntax, described in <a href="#6.9.1">6.9.1</a>.
</small>
-<a name="6.7.1" href="#6.7.1"><h4>6.7.1 Storage-class specifiers</h4></a>
+<h4><a name="6.7.1" href="#6.7.1">6.7.1 Storage-class specifiers</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
register is sizeof.
</small>
-<a name="6.7.2" href="#6.7.2"><h4>6.7.2 Type specifiers</h4></a>
+<h4><a name="6.7.2" href="#6.7.2">6.7.2 Type specifiers</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note104" href="#note104">104)</a> Freestanding implementations are not required to provide complex types. *
</small>
-<a name="6.7.2.1" href="#6.7.2.1"><h5>6.7.2.1 Structure and union specifiers</h5></a>
+<h5><a name="6.7.2.1" href="#6.7.2.1">6.7.2.1 Structure and union specifiers</a></h5>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
struct-or-union-specifier:
- struct-or-union identifieropt { struct-declaration-list }
+ struct-or-union identifier<sub>opt</sub> { struct-declaration-list }
struct-or-union identifier
struct-or-union:
struct
struct-declaration:
specifier-qualifier-list struct-declarator-list ;
specifier-qualifier-list:
- type-specifier specifier-qualifier-listopt
- type-qualifier specifier-qualifier-listopt
+ type-specifier specifier-qualifier-list<sub>opt</sub>
+ type-qualifier specifier-qualifier-list<sub>opt</sub>
struct-declarator-list:
struct-declarator
struct-declarator-list , struct-declarator
struct-declarator:
declarator
- declaratoropt : constant-expression</pre>
+ declarator<sub>opt</sub> : constant-expression</pre>
<h6>Constraints</h6>
<p><!--para 2 -->
A structure or union shall not contain a member with incomplete or function type (hence,
layouts.
</small>
-<a name="6.7.2.2" href="#6.7.2.2"><h5>6.7.2.2 Enumeration specifiers</h5></a>
+<h5><a name="6.7.2.2" href="#6.7.2.2">6.7.2.2 Enumeration specifiers</a></h5>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
enum-specifier:
- enum identifieropt { enumerator-list }
- enum identifieropt { enumerator-list , }
+ enum identifier<sub>opt</sub> { enumerator-list }
+ enum identifier<sub>opt</sub> { enumerator-list , }
enum identifier
enumerator-list:
enumerator
been seen.
</small>
-<a name="6.7.2.3" href="#6.7.2.3"><h5>6.7.2.3 Tags</h5></a>
+<h5><a name="6.7.2.3" href="#6.7.2.3">6.7.2.3 Tags</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
A specific type shall have its content defined at most once.
<p><!--para 6 -->
A type specifier of the form
<pre>
- struct-or-union identifieropt { struct-declaration-list }</pre>
+ struct-or-union identifier<sub>opt</sub> { struct-declaration-list }</pre>
or
<pre>
enum identifier { enumerator-list }</pre>
<p><small><a name="note113" href="#note113">113)</a> A similar construction with enum does not exist.
</small>
-<a name="6.7.3" href="#6.7.3"><h4>6.7.3 Type qualifiers</h4></a>
+<h4><a name="6.7.3" href="#6.7.3">6.7.3 Type qualifiers</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note118" href="#note118">118)</a> Both of these can occur through the use of typedefs.
</small>
-<a name="6.7.3.1" href="#6.7.3.1"><h5>6.7.3.1 Formal definition of restrict</h5></a>
+<h5><a name="6.7.3.1" href="#6.7.3.1">6.7.3.1 Formal definition of restrict</a></h5>
<p><!--para 1 -->
Let D be a declaration of an ordinary identifier that provides a means of designating an
object P as a restrict-qualified pointer to type T.
expressions *p and p[1] are not.
</small>
-<a name="6.7.4" href="#6.7.4"><h4>6.7.4 Function specifiers</h4></a>
+<h4><a name="6.7.4" href="#6.7.4">6.7.4 Function specifiers</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
duration are also distinct in each of the definitions.
</small>
-<a name="6.7.5" href="#6.7.5"><h4>6.7.5 Declarators</h4></a>
+<h4><a name="6.7.5" href="#6.7.5">6.7.5 Declarators</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
declarator:
- pointeropt direct-declarator
+ pointer<sub>opt</sub> direct-declarator
direct-declarator:
identifier
( declarator )
- direct-declarator [ type-qualifier-listopt assignment-expressionopt ]
- direct-declarator [ static type-qualifier-listopt assignment-expression ]
+ direct-declarator [ type-qualifier-list<sub>opt</sub> assignment-expression<sub>opt</sub> ]
+ direct-declarator [ static type-qualifier-list<sub>opt</sub> assignment-expression ]
direct-declarator [ type-qualifier-list static assignment-expression ]
- direct-declarator [ type-qualifier-listopt * ]
+ direct-declarator [ type-qualifier-list<sub>opt</sub> * ]
direct-declarator ( parameter-type-list )
- direct-declarator ( identifier-listopt )
+ direct-declarator ( identifier-list<sub>opt</sub> )
pointer:
- * type-qualifier-listopt
- * type-qualifier-listopt pointer
+ * type-qualifier-list<sub>opt</sub>
+ * type-qualifier-list<sub>opt</sub> pointer
type-qualifier-list:
type-qualifier
type-qualifier-list type-qualifier
parameter-list , parameter-declaration
parameter-declaration:
declaration-specifiers declarator
- declaration-specifiers abstract-declaratoropt
+ declaration-specifiers abstract-declarator<sub>opt</sub>
identifier-list:
identifier
identifier-list , identifier</pre>
then ident has the type specified by the declaration ''T D''. Thus, a declarator in
parentheses is identical to the unparenthesized declarator, but the binding of complicated
declarators may be altered by parentheses.
- Implementation limits
+<h6> Implementation limits</h6>
<p><!--para 7 -->
As discussed in <a href="#5.2.4.1">5.2.4.1</a>, an implementation may limit the number of pointer, array, and
function declarators that modify an arithmetic, structure, union, or incomplete type, either
directly or via one or more typedefs.
<p><b> Forward references</b>: array declarators (<a href="#6.7.5.2">6.7.5.2</a>), type definitions (<a href="#6.7.7">6.7.7</a>).
-<a name="6.7.5.1" href="#6.7.5.1"><h5>6.7.5.1 Pointer declarators</h5></a>
+<h5><a name="6.7.5.1" href="#6.7.5.1">6.7.5.1 Pointer declarators</a></h5>
<h6>Semantics</h6>
<p><!--para 1 -->
If, in the declaration ''T D1'', D1 has the form
<pre>
- * type-qualifier-listopt D</pre>
+ * type-qualifier-list<sub>opt</sub> D</pre>
and the type specified for ident in the declaration ''T D'' is ''derived-declarator-type-list
T '', then the type specified for ident is ''derived-declarator-type-list type-qualifier-list
pointer to T ''. For each type qualifier in the list, ident is a so-qualified pointer.
declares constant_ptr as an object that has type ''const-qualified pointer to int''.
-<a name="6.7.5.2" href="#6.7.5.2"><h5>6.7.5.2 Array declarators</h5></a>
+<h5><a name="6.7.5.2" href="#6.7.5.2">6.7.5.2 Array declarators</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
In addition to optional type qualifiers and the keyword static, the [ and ] may delimit
<p><!--para 3 -->
If, in the declaration ''T D1'', D1 has one of the forms:
<pre>
- D[ type-qualifier-listopt assignment-expressionopt ]
- D[ static type-qualifier-listopt assignment-expression ]
+ D[ type-qualifier-list<sub>opt</sub> assignment-expressionopt ]
+ D[ static type-qualifier-list<sub>opt</sub> assignment-expression ]
D[ type-qualifier-list static assignment-expression ]
- D[ type-qualifier-listopt * ]</pre>
+ D[ type-qualifier-list<sub>opt</sub> * ]</pre>
and the type specified for ident in the declaration ''T D'' is ''derived-declarator-type-list
T '', then the type specified for ident is ''derived-declarator-type-list array of T ''.<sup><a href="#note123"><b>123)</b></a></sup>
(See <a href="#6.7.5.3">6.7.5.3</a> for the meaning of the optional type qualifiers and the keyword static.)
<p><small><a name="note124" href="#note124">124)</a> Thus, * can be used only in function declarations that are not definitions (see <a href="#6.7.5.3">6.7.5.3</a>).
</small>
-<a name="6.7.5.3" href="#6.7.5.3"><h5>6.7.5.3 Function declarators (including prototypes)</h5></a>
+<h5><a name="6.7.5.3" href="#6.7.5.3">6.7.5.3 Function declarators (including prototypes)</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
A function declarator shall not specify a return type that is a function type or an array
or
<!--page 131 -->
<pre>
- D( identifier-listopt )</pre>
+ D( identifier-list<sub>opt</sub> )</pre>
and the type specified for ident in the declaration ''T D'' is ''derived-declarator-type-list
T '', then the type specified for ident is ''derived-declarator-type-list function returning
T ''.
<p><small><a name="note127" href="#note127">127)</a> If both function types are ''old style'', parameter types are not compared.
</small>
-<a name="6.7.6" href="#6.7.6"><h4>6.7.6 Type names</h4></a>
+<h4><a name="6.7.6" href="#6.7.6">6.7.6 Type names</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
type-name:
- specifier-qualifier-list abstract-declaratoropt
+ specifier-qualifier-list abstract-declarator<sub>opt</sub>
abstract-declarator:
pointer
- pointeropt direct-abstract-declarator
+ pointer<sub>opt</sub> direct-abstract-declarator
direct-abstract-declarator:
( abstract-declarator )
- direct-abstract-declaratoropt [ type-qualifier-listopt
- assignment-expressionopt ]
- direct-abstract-declaratoropt [ static type-qualifier-listopt
+ direct-abstract-declarator<sub>opt</sub> [ type-qualifier-list<sub>opt</sub>
+ assignment-expression<sub>opt</sub> ]
+ direct-abstract-declarator<sub>opt</sub> [ static type-qualifier-list<sub>opt</sub>
assignment-expression ]
- direct-abstract-declaratoropt [ type-qualifier-list static
+ direct-abstract-declarator<sub>opt</sub> [ type-qualifier-list static
assignment-expression ]
- direct-abstract-declaratoropt [ * ]
- direct-abstract-declaratoropt ( parameter-type-listopt )</pre>
+ direct-abstract-declarator<sub>opt</sub> [ * ]
+ direct-abstract-declarator<sub>opt</sub> ( parameter-type-list<sub>opt</sub> )</pre>
<h6>Semantics</h6>
<p><!--para 2 -->
In several contexts, it is necessary to specify a type. This is accomplished using a type
parameter specification'', rather than redundant parentheses around the omitted identifier.
</small>
-<a name="6.7.7" href="#6.7.7"><h4>6.7.7 Type definitions</h4></a>
+<h4><a name="6.7.7" href="#6.7.7">6.7.7 Type definitions</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
a[i-1] = b[i];
}</pre>
-<a name="6.7.8" href="#6.7.8"><h4>6.7.8 Initialization</h4></a>
+<h4><a name="6.7.8" href="#6.7.8">6.7.8 Initialization</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
{ initializer-list , }
initializer-list:
designationopt initializer
- initializer-list , designationopt initializer
+ initializer-list , designation<sub>opt</sub> initializer
designation:
designator-list =
designator-list:
<p><small><a name="note133" href="#note133">133)</a> In particular, the evaluation order need not be the same as the order of subobject initialization.
</small>
-<a name="6.8" href="#6.8"><h3>6.8 Statements and blocks</h3></a>
+<h3><a name="6.8" href="#6.8">6.8 Statements and blocks</a></h3>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
<p><b> Forward references</b>: expression and null statements (<a href="#6.8.3">6.8.3</a>), selection statements
(<a href="#6.8.4">6.8.4</a>), iteration statements (<a href="#6.8.5">6.8.5</a>), the return statement (<a href="#6.8.6.4">6.8.6.4</a>).
-<a name="6.8.1" href="#6.8.1"><h4>6.8.1 Labeled statements</h4></a>
+<h4><a name="6.8.1" href="#6.8.1">6.8.1 Labeled statements</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
them.
<p><b> Forward references</b>: the goto statement (<a href="#6.8.6.1">6.8.6.1</a>), the switch statement (<a href="#6.8.4.2">6.8.4.2</a>).
-<a name="6.8.2" href="#6.8.2"><h4>6.8.2 Compound statement</h4></a>
+<h4><a name="6.8.2" href="#6.8.2">6.8.2 Compound statement</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
compound-statement:
- { block-item-listopt }
+ { block-item-list<sub>opt</sub> }
block-item-list:
block-item
block-item-list block-item
<p><!--para 2 -->
A compound statement is a block.
-<a name="6.8.3" href="#6.8.3"><h4>6.8.3 Expression and null statements</h4></a>
+<h4><a name="6.8.3" href="#6.8.3">6.8.3 Expression and null statements</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
expression-statement:
- expressionopt ;</pre>
+ expression<sub>opt</sub> ;</pre>
<h6>Semantics</h6>
<p><!--para 2 -->
The expression in an expression statement is evaluated as a void expression for its side
<p><small><a name="note134" href="#note134">134)</a> Such as assignments, and function calls which have side effects.
</small>
-<a name="6.8.4" href="#6.8.4"><h4>6.8.4 Selection statements</h4></a>
+<h4><a name="6.8.4" href="#6.8.4">6.8.4 Selection statements</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
enclosing block. Each associated substatement is also a block whose scope is a strict
subset of the scope of the selection statement.
-<a name="6.8.4.1" href="#6.8.4.1"><h5>6.8.4.1 The if statement</h5></a>
+<h5><a name="6.8.4.1" href="#6.8.4.1">6.8.4.1 The if statement</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The controlling expression of an if statement shall have scalar type.
An else is associated with the lexically nearest preceding if that is allowed by the
syntax.
-<a name="6.8.4.2" href="#6.8.4.2"><h5>6.8.4.2 The switch statement</h5></a>
+<h5><a name="6.8.4.2" href="#6.8.4.2">6.8.4.2 The switch statement</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The controlling expression of a switch statement shall have integer type.
a default label, control jumps to the labeled statement. If no converted case constant
expression matches and there is no default label, no part of the switch body is
executed.
- Implementation limits
+<h6> Implementation limits</h6>
<p><!--para 6 -->
As discussed in <a href="#5.2.4.1">5.2.4.1</a>, the implementation may limit the number of case values in a
switch statement.
default label associated with the switch that is in the block containing the declaration.
</small>
-<a name="6.8.5" href="#6.8.5"><h4>6.8.5 Iteration statements</h4></a>
+<h4><a name="6.8.5" href="#6.8.5">6.8.5 Iteration statements</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
iteration-statement:
while ( expression ) statement
do statement while ( expression ) ;
- for ( expressionopt ; expressionopt ; expressionopt ) statement
- for ( declaration expressionopt ; expressionopt ) statement</pre>
+ for ( expression<sub>opt</sub> ; expression<sub>opt</sub> ; expression<sub>opt</sub> ) statement
+ for ( declaration expression<sub>opt</sub> ; expression<sub>opt</sub> ) statement</pre>
<h6>Constraints</h6>
<p><!--para 2 -->
The controlling expression of an iteration statement shall have scalar type.
statement is not evaluated before entering the loop body, nor is clause-1 of a for statement.
</small>
-<a name="6.8.5.1" href="#6.8.5.1"><h5>6.8.5.1 The while statement</h5></a>
+<h5><a name="6.8.5.1" href="#6.8.5.1">6.8.5.1 The while statement</a></h5>
<p><!--para 1 -->
The evaluation of the controlling expression takes place before each execution of the loop
body.
-<a name="6.8.5.2" href="#6.8.5.2"><h5>6.8.5.2 The do statement</h5></a>
+<h5><a name="6.8.5.2" href="#6.8.5.2">6.8.5.2 The do statement</a></h5>
<p><!--para 1 -->
The evaluation of the controlling expression takes place after each execution of the loop
body.
-<a name="6.8.5.3" href="#6.8.5.3"><h5>6.8.5.3 The for statement</h5></a>
+<h5><a name="6.8.5.3" href="#6.8.5.3">6.8.5.3 The for statement</a></h5>
<p><!--para 1 -->
The statement
<pre>
specifies an operation (such as incrementing) that is performed after each iteration.
</small>
-<a name="6.8.6" href="#6.8.6"><h4>6.8.6 Jump statements</h4></a>
+<h4><a name="6.8.6" href="#6.8.6">6.8.6 Jump statements</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
goto identifier ;
continue ;
break ;
- return expressionopt ;</pre>
+ return expression<sub>opt</sub> ;</pre>
<h6>Semantics</h6>
<p><!--para 2 -->
A jump statement causes an unconditional jump to another place.
<!--page 149 -->
-<a name="6.8.6.1" href="#6.8.6.1"><h5>6.8.6.1 The goto statement</h5></a>
+<h5><a name="6.8.6.1" href="#6.8.6.1">6.8.6.1 The goto statement</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
The identifier in a goto statement shall name a label located somewhere in the enclosing
<li> The general initialization code is too large to warrant duplication.
<li> The code to determine the next operation is at the head of the loop. (To allow it to be reached by
continue statements, for example.)
+<pre>
/* ... */
goto first_time;
for (;;) {
-<pre>
// determine next operation
/* ... */
if (need to reinitialize) {
continue;
}
// handle other operations
- /* ... */</pre>
- }
+ /* ... */
+ }</pre>
<!--page 150 -->
</ol>
<p><!--para 4 -->
goto lab4; // invalid: going INTO scope of VLA.</pre>
-<a name="6.8.6.2" href="#6.8.6.2"><h5>6.8.6.2 The continue statement</h5></a>
+<h5><a name="6.8.6.2" href="#6.8.6.2">6.8.6.2 The continue statement</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
A continue statement shall appear only in or as a loop body.
A continue statement causes a jump to the loop-continuation portion of the smallest
enclosing iteration statement; that is, to the end of the loop body. More precisely, in each
of the statements
- while (/* ... */) { do { for (/* ... */) {
<pre>
+ while (/* ... */) { do { for (/* ... */) {
/* ... */ /* ... */ /* ... */
continue; continue; continue;
- /* ... */ /* ... */ /* ... */</pre>
+ /* ... */ /* ... */ /* ... */
contin: ; contin: ; contin: ;
- } } while (/* ... */); }
+ } } while (/* ... */); }</pre>
unless the continue statement shown is in an enclosed iteration statement (in which
case it is interpreted within that statement), it is equivalent to goto contin;.<sup><a href="#note138"><b>138)</b></a></sup>
<p><small><a name="note138" href="#note138">138)</a> Following the contin: label is a null statement.
</small>
-<a name="6.8.6.3" href="#6.8.6.3"><h5>6.8.6.3 The break statement</h5></a>
+<h5><a name="6.8.6.3" href="#6.8.6.3">6.8.6.3 The break statement</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
A break statement shall appear only in or as a switch body or loop body.
<!--page 151 -->
-<a name="6.8.6.4" href="#6.8.6.4"><h5>6.8.6.4 The return statement</h5></a>
+<h5><a name="6.8.6.4" href="#6.8.6.4">6.8.6.4 The return statement</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
A return statement with an expression shall not appear in a function whose return type
range and precision.
</small>
-<a name="6.9" href="#6.9"><h3>6.9 External definitions</h3></a>
+<h3><a name="6.9" href="#6.9">6.9 External definitions</a></h3>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
external definition for it.
</small>
-<a name="6.9.1" href="#6.9.1"><h4>6.9.1 Function definitions</h4></a>
+<h4><a name="6.9.1" href="#6.9.1">6.9.1 Function definitions</a></h4>
<h6>Syntax</h6>
<p><!--para 1 -->
<pre>
function-definition:
- declaration-specifiers declarator declaration-listopt compound-statement
+ declaration-specifiers declarator declaration-list<sub>opt</sub> compound-statement
declaration-list:
declaration
declaration-list declaration</pre>
<p><small><a name="note142" href="#note142">142)</a> See ''future language directions'' (<a href="#6.11.7">6.11.7</a>).
</small>
-<a name="6.9.2" href="#6.9.2"><h4>6.9.2 External object definitions</h4></a>
+<h4><a name="6.9.2" href="#6.9.2">6.9.2 External object definitions</a></h4>
<h6>Semantics</h6>
<p><!--para 1 -->
If the declaration of an identifier for an object has file scope and an initializer, the
zero on program startup.
<!--page 157 -->
-<a name="6.10" href="#6.10"><h3>6.10 Preprocessing directives</h3></a>
+<h3><a name="6.10" href="#6.10">6.10 Preprocessing directives</a></h3>
<h6>Syntax</h6>
<p><!--para 1 -->
<!--page 158 -->
<pre>
preprocessing-file:
- groupopt
+ group<sub>opt</sub>
group:
group-part
group group-part
text-line
# non-directive
if-section:
- if-group elif-groupsopt else-groupopt endif-line
+ if-group elif-groups<sub>opt</sub> else-group<sub>opt</sub> endif-line
if-group:
- # if constant-expression new-line groupopt
- # ifdef identifier new-line groupopt
- # ifndef identifier new-line groupopt
+ # if constant-expression new-line group<sub>opt</sub>
+ # ifdef identifier new-line group<sub>opt</sub>
+ # ifndef identifier new-line group<sub>opt</sub>
elif-groups:
elif-group
elif-groups elif-group
elif-group:
- # elif constant-expression new-line groupopt
+ # elif constant-expression new-line group<sub>opt</sub>
else-group:
- # else new-line groupopt
+ # else new-line group<sub>opt</sub>
endif-line:
# endif new-line
control-line:
# include pp-tokens new-line
# define identifier replacement-list new-line
- # define identifier lparen identifier-listopt )
+ # define identifier lparen identifier-list<sub>opt</sub> )
replacement-list new-line
# define identifier lparen ... ) replacement-list new-line
# define identifier lparen identifier-list , ... )
replacement-list new-line
# undef identifier new-line
# line pp-tokens new-line
- # error pp-tokensopt new-line
- # pragma pp-tokensopt new-line
+ # error pp-tokens<sub>opt</sub> new-line
+ # pragma pp-tokens<sub>opt</sub> new-line
# new-line
text-line:
- pp-tokensopt new-line
+ pp-tokens<sub>opt</sub> new-line
non-directive:
pp-tokens new-line
lparen:
a ( character not immediately preceded by white-space
replacement-list:
- pp-tokensopt
+ pp-tokens<sub>opt</sub>
pp-tokens:
preprocessing-token
pp-tokens preprocessing-token
# character string literal creation operator in <a href="#6.10.3.2">6.10.3.2</a>, for example).
</small>
-<a name="6.10.1" href="#6.10.1"><h4>6.10.1 Conditional inclusion</h4></a>
+<h4><a name="6.10.1" href="#6.10.1">6.10.1 Conditional inclusion</a></h4>
<h6>Constraints</h6>
<p><!--para 1 -->
The expression that controls conditional inclusion shall be an integer constant expression
<p><!--para 3 -->
Preprocessing directives of the forms
<pre>
- # if constant-expression new-line groupopt
- # elif constant-expression new-line groupopt</pre>
+ # if constant-expression new-line group<sub>opt</sub>
+ # elif constant-expression new-line group<sub>opt</sub></pre>
check whether the controlling constant expression evaluates to nonzero.
<p><!--para 4 -->
Prior to evaluation, macro invocations in the list of preprocessing tokens that will become
<!--page 161 -->
<pre>
- # ifdef identifier new-line groupopt
- # ifndef identifier new-line groupopt</pre>
+ # ifdef identifier new-line group<sub>opt</sub>
+ # ifndef identifier new-line group<sub>opt</sub></pre>
check whether the identifier is or is not currently defined as a macro name. Their
conditions are equivalent to #if defined identifier and #if !defined identifier
respectively.
</small>
<p><small><a name="note146" href="#note146">146)</a> Thus, the constant expression in the following #if directive and if statement is not guaranteed to
evaluate to the same value in these two contexts.
+<pre>
#if 'z' - 'a' == 25
- if ('z' - 'a' == 25)
+ if ('z' - 'a' == 25)</pre>
</small>
<p><small><a name="note147" href="#note147">147)</a> As indicated by the syntax, a preprocessing token shall not follow a #else or #endif directive
including within a preprocessing directive.
</small>
-<a name="6.10.2" href="#6.10.2"><h4>6.10.2 Source file inclusion</h4></a>
+<h4><a name="6.10.2" href="#6.10.2">6.10.2 Source file inclusion</a></h4>
<h6>Constraints</h6>
<p><!--para 1 -->
A #include directive shall identify a header or source file that can be processed by the
phases in <a href="#5.1.1.2">5.1.1.2</a>); thus, an expansion that results in two string literals is an invalid directive.
</small>
-<a name="6.10.3" href="#6.10.3"><h4>6.10.3 Macro replacement</h4></a>
+<h4><a name="6.10.3" href="#6.10.3">6.10.3 Macro replacement</a></h4>
<h6>Constraints</h6>
<p><!--para 1 -->
Two replacement lists are identical if and only if the preprocessing tokens in both have
<p><!--para 10 -->
A preprocessing directive of the form
<pre>
- # define identifier lparen identifier-listopt ) replacement-list new-line
+ # define identifier lparen identifier-list<sub>opt</sub> ) replacement-list new-line
# define identifier lparen ... ) replacement-list new-line
# define identifier lparen identifier-list , ... ) replacement-list new-line</pre>
defines a function-like macro with parameters, whose use is similar syntactically to a
<p><small><a name="note150" href="#note150">150)</a> Despite the name, a non-directive is a preprocessing directive.
</small>
-<a name="6.10.3.1" href="#6.10.3.1"><h5>6.10.3.1 Argument substitution</h5></a>
+<h5><a name="6.10.3.1" href="#6.10.3.1">6.10.3.1 Argument substitution</a></h5>
<p><!--para 1 -->
After the arguments for the invocation of a function-like macro have been identified,
argument substitution takes place. A parameter in the replacement list, unless preceded
were a parameter, and the variable arguments shall form the preprocessing tokens used to
replace it.
-<a name="6.10.3.2" href="#6.10.3.2"><h5>6.10.3.2 The # operator</h5></a>
+<h5><a name="6.10.3.2" href="#6.10.3.2">6.10.3.2 The # operator</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
Each # preprocessing token in the replacement list for a function-like macro shall be
## operators is unspecified.
<!--page 166 -->
-<a name="6.10.3.3" href="#6.10.3.3"><h5>6.10.3.3 The ## operator</h5></a>
+<h5><a name="6.10.3.3" href="#6.10.3.3">6.10.3.3 The ## operator</a></h5>
<h6>Constraints</h6>
<p><!--para 1 -->
A ## preprocessing token shall not occur at the beginning or at the end of a replacement
exist only within translation phase 4.
</small>
-<a name="6.10.3.4" href="#6.10.3.4"><h5>6.10.3.4 Rescanning and further replacement</h5></a>
+<h5><a name="6.10.3.4" href="#6.10.3.4">6.10.3.4 Rescanning and further replacement</a></h5>
<p><!--para 1 -->
After all parameters in the replacement list have been substituted and # and ##
processing has taken place, all placemarker preprocessing tokens are removed. Then, the
as a preprocessing directive even if it resembles one, but all pragma unary operator
expressions within it are then processed as specified in <a href="#6.10.9">6.10.9</a> below.
-<a name="6.10.3.5" href="#6.10.3.5"><h5>6.10.3.5 Scope of macro definitions</h5></a>
+<h5><a name="6.10.3.5" href="#6.10.3.5">6.10.3.5 Scope of macro definitions</a></h5>
<p><!--para 1 -->
A macro definition lasts (independent of block structure) until a corresponding #undef
directive is encountered or (if none is encountered) until the end of the preprocessing
printf("x is %d but y is %d", x, y));</pre>
-<a name="6.10.4" href="#6.10.4"><h4>6.10.4 Line control</h4></a>
+<h4><a name="6.10.4" href="#6.10.4">6.10.4 Line control</a></h4>
<h6>Constraints</h6>
<p><!--para 1 -->
The string literal of a #line directive, if present, shall be a character string literal.
<p><!--para 4 -->
A preprocessing directive of the form
<pre>
- # line digit-sequence "s-char-sequenceopt" new-line</pre>
+ # line digit-sequence "s-char-sequence<sub>opt</sub>" new-line</pre>
sets the presumed line number similarly and changes the presumed name of the source
file to be the contents of the character string literal.
<p><!--para 5 -->
previous forms and is then processed as appropriate.
<!--page 171 -->
-<a name="6.10.5" href="#6.10.5"><h4>6.10.5 Error directive</h4></a>
+<h4><a name="6.10.5" href="#6.10.5">6.10.5 Error directive</a></h4>
<h6>Semantics</h6>
<p><!--para 1 -->
A preprocessing directive of the form
<pre>
- # error pp-tokensopt new-line</pre>
+ # error pp-tokens<sub>opt</sub> new-line</pre>
causes the implementation to produce a diagnostic message that includes the specified
sequence of preprocessing tokens.
-<a name="6.10.6" href="#6.10.6"><h4>6.10.6 Pragma directive</h4></a>
+<h4><a name="6.10.6" href="#6.10.6">6.10.6 Pragma directive</a></h4>
<h6>Semantics</h6>
<p><!--para 1 -->
A preprocessing directive of the form
<pre>
- # pragma pp-tokensopt new-line</pre>
+ # pragma pp-tokens<sub>opt</sub> new-line</pre>
where the preprocessing token STDC does not immediately follow pragma in the
directive (prior to any macro replacement)<sup><a href="#note152"><b>152)</b></a></sup> causes the implementation to behave in an
implementation-defined manner. The behavior might cause translation to fail or cause the
<p><small><a name="note153" href="#note153">153)</a> See ''future language directions'' (<a href="#6.11.8">6.11.8</a>).
</small>
-<a name="6.10.7" href="#6.10.7"><h4>6.10.7 Null directive</h4></a>
+<h4><a name="6.10.7" href="#6.10.7">6.10.7 Null directive</a></h4>
<h6>Semantics</h6>
<p><!--para 1 -->
A preprocessing directive of the form
# new-line</pre>
has no effect.
-<a name="6.10.8" href="#6.10.8"><h4>6.10.8 Predefined macro names</h4></a>
+<h4><a name="6.10.8" href="#6.10.8">6.10.8 Predefined macro names</a></h4>
<p><!--para 1 -->
The following macro names<sup><a href="#note154"><b>154)</b></a></sup> shall be defined by the implementation:
- __DATE__ The date of translation of the preprocessing translation unit: a character
-<pre>
+<dl>
+<dt> __DATE__ <dd>The date of translation of the preprocessing translation unit: a character
string literal of the form "Mmm dd yyyy", where the names of the
months are the same as those generated by the asctime function, and the
first character of dd is a space character if the value is less than 10. If the
date of translation is not available, an implementation-defined valid date
- shall be supplied.</pre>
- __FILE__ The presumed name of the current source file (a character string literal).<sup><a href="#note155"><b>155)</b></a></sup>
- __LINE__ The presumed line number (within the current source file) of the current
-<pre>
- source line (an integer constant).155)</pre>
- __STDC__ The integer constant 1, intended to indicate a conforming implementation.
- __STDC_HOSTED__ The integer constant 1 if the implementation is a hosted
-<pre>
- implementation or the integer constant 0 if it is not.</pre>
- __STDC_MB_MIGHT_NEQ_WC__ The integer constant 1, intended to indicate that, in
-<pre>
+ shall be supplied.
+<dt> __FILE__ <dd>The presumed name of the current source file (a character string literal).<sup><a href="#note155"><b>155)</b></a></sup>
+<dt> __LINE__ <dd>The presumed line number (within the current source file) of the current
+ source line (an integer constant).<sup><a href="#note155"><b>155)</b></a></sup>
+<dt> __STDC__ <dd>The integer constant 1, intended to indicate a conforming implementation.
+<dt> __STDC_HOSTED__ <dd>The integer constant 1 if the implementation is a hosted
+ implementation or the integer constant 0 if it is not.
+<dt> __STDC_MB_MIGHT_NEQ_WC__ <dd>The integer constant 1, intended to indicate that, in
the encoding for wchar_t, a member of the basic character set need not
have a code value equal to its value when used as the lone character in an
- integer character constant.</pre>
- __STDC_VERSION__ The integer constant 199901L.<sup><a href="#note156"><b>156)</b></a></sup>
- __TIME__ The time of translation of the preprocessing translation unit: a character
-<pre>
+ integer character constant.
+<dt> __STDC_VERSION__ <dd>The integer constant 199901L.<sup><a href="#note156"><b>156)</b></a></sup>
+<dt> __TIME__ <dd>The time of translation of the preprocessing translation unit: a character
string literal of the form "hh:mm:ss" as in the time generated by the
asctime function. If the time of translation is not available, an
- implementation-defined valid time shall be supplied.</pre>
-
+ implementation-defined valid time shall be supplied.
+</dl>
<!--page 173 -->
<p><!--para 2 -->
The following macro names are conditionally defined by the implementation:
- __STDC_IEC_559__ The integer constant 1, intended to indicate conformance to the
-<pre>
- specifications in <a href="#F">annex F</a> (IEC 60559 floating-point arithmetic).</pre>
- __STDC_IEC_559_COMPLEX__ The integer constant 1, intended to indicate
-<pre>
+<dl>
+<dt> __STDC_IEC_559__ <dd>The integer constant 1, intended to indicate conformance to the
+ specifications in <a href="#F">annex F</a> (IEC 60559 floating-point arithmetic).
+<dt> __STDC_IEC_559_COMPLEX__ <dd>The integer constant 1, intended to indicate
adherence to the specifications in informative <a href="#G">annex G</a> (IEC 60559
- compatible complex arithmetic).</pre>
- __STDC_ISO_10646__ An integer constant of the form yyyymmL (for example,
-<p><!--para 3 -->
-<pre>
+ compatible complex arithmetic).
+<dt> __STDC_ISO_10646__ <dd>An integer constant of the form yyyymmL (for example,
199712L). If this symbol is defined, then every character in the Unicode
required set, when stored in an object of type wchar_t, has the same
value as the short identifier of that character. The Unicode required set
consists of all the characters that are defined by ISO/IEC 10646, along with
all amendments and technical corrigenda, as of the specified year and
- month.</pre>
+ month.
+</dl>
+<p><!--para 3 -->
The values of the predefined macros (except for __FILE__ and __LINE__) remain
constant throughout the translation unit.
<p><!--para 4 -->
int that is increased with each revision of this International Standard.
</small>
-<a name="6.10.9" href="#6.10.9"><h4>6.10.9 Pragma operator</h4></a>
+<h4><a name="6.10.9" href="#6.10.9">6.10.9 Pragma operator</a></h4>
<h6>Semantics</h6>
<p><!--para 1 -->
A unary operator expression of the form:
#define PRAGMA(x) _Pragma(#x)
LISTING ( ..\listing.dir )</pre>
-<a name="6.11" href="#6.11"><h3>6.11 Future language directions</h3></a>
+<h3><a name="6.11" href="#6.11">6.11 Future language directions</a></h3>
-<a name="6.11.1" href="#6.11.1"><h4>6.11.1 Floating types</h4></a>
+<h4><a name="6.11.1" href="#6.11.1">6.11.1 Floating types</a></h4>
<p><!--para 1 -->
Future standardization may include additional floating-point types, including those with
greater range, precision, or both than long double.
-<a name="6.11.2" href="#6.11.2"><h4>6.11.2 Linkages of identifiers</h4></a>
+<h4><a name="6.11.2" href="#6.11.2">6.11.2 Linkages of identifiers</a></h4>
<p><!--para 1 -->
Declaring an identifier with internal linkage at file scope without the static storage-
class specifier is an obsolescent feature.
-<a name="6.11.3" href="#6.11.3"><h4>6.11.3 External names</h4></a>
+<h4><a name="6.11.3" href="#6.11.3">6.11.3 External names</a></h4>
<p><!--para 1 -->
Restriction of the significance of an external name to fewer than 255 characters
(considering each universal character name or extended source character as a single
character) is an obsolescent feature that is a concession to existing implementations.
-<a name="6.11.4" href="#6.11.4"><h4>6.11.4 Character escape sequences</h4></a>
+<h4><a name="6.11.4" href="#6.11.4">6.11.4 Character escape sequences</a></h4>
<p><!--para 1 -->
Lowercase letters as escape sequences are reserved for future standardization. Other
characters may be used in extensions.
-<a name="6.11.5" href="#6.11.5"><h4>6.11.5 Storage-class specifiers</h4></a>
+<h4><a name="6.11.5" href="#6.11.5">6.11.5 Storage-class specifiers</a></h4>
<p><!--para 1 -->
The placement of a storage-class specifier other than at the beginning of the declaration
specifiers in a declaration is an obsolescent feature.
-<a name="6.11.6" href="#6.11.6"><h4>6.11.6 Function declarators</h4></a>
+<h4><a name="6.11.6" href="#6.11.6">6.11.6 Function declarators</a></h4>
<p><!--para 1 -->
The use of function declarators with empty parentheses (not prototype-format parameter
type declarators) is an obsolescent feature.
-<a name="6.11.7" href="#6.11.7"><h4>6.11.7 Function definitions</h4></a>
+<h4><a name="6.11.7" href="#6.11.7">6.11.7 Function definitions</a></h4>
<p><!--para 1 -->
The use of function definitions with separate parameter identifier and declaration lists
(not prototype-format parameter type and identifier declarators) is an obsolescent feature.
-<a name="6.11.8" href="#6.11.8"><h4>6.11.8 Pragma directives</h4></a>
+<h4><a name="6.11.8" href="#6.11.8">6.11.8 Pragma directives</a></h4>
<p><!--para 1 -->
Pragmas whose first preprocessing token is STDC are reserved for future standardization.
-<a name="6.11.9" href="#6.11.9"><h4>6.11.9 Predefined macro names</h4></a>
+<h4><a name="6.11.9" href="#6.11.9">6.11.9 Predefined macro names</a></h4>
<p><!--para 1 -->
Macro names beginning with __STDC_ are reserved for future standardization.
<!--page 176 -->
-<a name="7" href="#7"><h2>7. Library</h2></a>
+<h2><a name="7" href="#7">7. Library</a></h2>
-<a name="7.1" href="#7.1"><h3>7.1 Introduction</h3></a>
+<h3><a name="7.1" href="#7.1">7.1 Introduction</a></h3>
-<a name="7.1.1" href="#7.1.1"><h4>7.1.1 Definitions of terms</h4></a>
+<h4><a name="7.1.1" href="#7.1.1">7.1.1 Definitions of terms</a></h4>
<p><!--para 1 -->
A string is a contiguous sequence of characters terminated by and including the first null
character. The term multibyte string is sometimes used instead to emphasize special
implementation's choice.
</small>
-<a name="7.1.2" href="#7.1.2"><h4>7.1.2 Standard headers</h4></a>
+<h4><a name="7.1.2" href="#7.1.2">7.1.2 Standard headers</a></h4>
<p><!--para 1 -->
Each library function is declared, with a type that includes a prototype, in a header,<sup><a href="#note159"><b>159)</b></a></sup>
whose contents are made available by the #include preprocessing directive. The
necessarily valid source file names.
</small>
-<a name="7.1.3" href="#7.1.3"><h4>7.1.3 Reserved identifiers</h4></a>
+<h4><a name="7.1.3" href="#7.1.3">7.1.3 Reserved identifiers</a></h4>
<p><!--para 1 -->
Each header declares or defines all identifiers listed in its associated subclause, and
optionally declares or defines identifiers listed in its associated future library directions
setjmp, and va_end.
</small>
-<a name="7.1.4" href="#7.1.4"><h4>7.1.4 Use of library functions</h4></a>
+<h4><a name="7.1.4" href="#7.1.4">7.1.4 Use of library functions</a></h4>
<p><!--para 1 -->
Each of the following statements applies unless explicitly stated otherwise in the detailed
descriptions that follow: If an argument to a function has an invalid value (such as a value
<p><small><a name="note164" href="#note164">164)</a> Thus, a signal handler cannot, in general, call standard library functions.
</small>
-<a name="7.2" href="#7.2"><h3>7.2 Diagnostics <assert.h></h3></a>
+<h3><a name="7.2" href="#7.2">7.2 Diagnostics <assert.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.2"><assert.h></a> defines the assert macro and refers to another macro,
<pre>
macro definition is suppressed in order to access an actual function, the behavior is
undefined.
-<a name="7.2.1" href="#7.2.1"><h4>7.2.1 Program diagnostics</h4></a>
+<h4><a name="7.2.1" href="#7.2.1">7.2.1 Program diagnostics</a></h4>
-<a name="7.2.1.1" href="#7.2.1.1"><h5>7.2.1.1 The assert macro</h5></a>
+<h5><a name="7.2.1.1" href="#7.2.1.1">7.2.1.1 The assert macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
Assertion failed: expression, function abc, file xyz, line nnn.
</small>
-<a name="7.3" href="#7.3"><h3>7.3 Complex arithmetic <complex.h></h3></a>
+<h3><a name="7.3" href="#7.3">7.3 Complex arithmetic <complex.h></a></h3>
-<a name="7.3.1" href="#7.3.1"><h4>7.3.1 Introduction</h4></a>
+<h4><a name="7.3.1" href="#7.3.1">7.3.1 Introduction</a></h4>
<p><!--para 1 -->
The header <a href="#7.3"><complex.h></a> defines macros and declares functions that support complex
arithmetic.<sup><a href="#note166"><b>166)</b></a></sup> Each synopsis specifies a family of functions consisting of a principal
<h6>footnotes</h6>
<p><small><a name="note166" href="#note166">166)</a> See ''future library directions'' (<a href="#7.26.1">7.26.1</a>).
</small>
-<p><small><a name="note167" href="#note167">167)</a> The imaginary unit is a number i such that i 2 = -1.
+<p><small><a name="note167" href="#note167">167)</a> The imaginary unit is a number i such that i<sup>2</sup> = -1.
</small>
<p><small><a name="note168" href="#note168">168)</a> A specification for imaginary types is in informative <a href="#G">annex G</a>.
</small>
-<a name="7.3.2" href="#7.3.2"><h4>7.3.2 Conventions</h4></a>
+<h4><a name="7.3.2" href="#7.3.2">7.3.2 Conventions</a></h4>
<p><!--para 1 -->
Values are interpreted as radians, not degrees. An implementation may set errno but is
not required to.
-<a name="7.3.3" href="#7.3.3"><h4>7.3.3 Branch cuts</h4></a>
+<h4><a name="7.3.3" href="#7.3.3">7.3.3 Branch cuts</a></h4>
<p><!--para 1 -->
Some of the functions below have branch cuts, across which the function is
discontinuous. For implementations with a signed zero (including all IEC 60559
the finite endpoint of the cut along the negative real axis approaches the cut from above,
so the cut maps to the positive imaginary axis.
-<a name="7.3.4" href="#7.3.4"><h4>7.3.4 The CX_LIMITED_RANGE pragma</h4></a>
+<h4><a name="7.3.4" href="#7.3.4">7.3.4 The CX_LIMITED_RANGE pragma</a></h4>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<pre>
(x + iy) x (u + iv) = (xu - yv) + i(yu + xv)
- (x + iy) / (u + iv) = [(xu + yv) + i(yu - xv)]/(u2 + v 2 )
- | x + iy | = (sqrt) x 2 + y 2
- ???????????????</pre>
+ (x + iy) / (u + iv) = [(xu + yv) + i(yu - xv)]/(u<sup>2</sup> + v<sup>2</sup>)
+ | x + iy | = (sqrt)(x<sup>2</sup> + y<sup>2</sup>)
+</pre>
where the programmer can determine they are safe.
</small>
-<a name="7.3.5" href="#7.3.5"><h4>7.3.5 Trigonometric functions</h4></a>
+<h4><a name="7.3.5" href="#7.3.5">7.3.5 Trigonometric functions</a></h4>
-<a name="7.3.5.1" href="#7.3.5.1"><h5>7.3.5.1 The cacos functions</h5></a>
+<h5><a name="7.3.5.1" href="#7.3.5.1">7.3.5.1 The cacos functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
mathematically unbounded along the imaginary axis and in the interval [0, pi ] along the
real axis.
-<a name="7.3.5.2" href="#7.3.5.2"><h5>7.3.5.2 The casin functions</h5></a>
+<h5><a name="7.3.5.2" href="#7.3.5.2">7.3.5.2 The casin functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
along the real axis.
<!--page 185 -->
-<a name="7.3.5.3" href="#7.3.5.3"><h5>7.3.5.3 The catan functions</h5></a>
+<h5><a name="7.3.5.3" href="#7.3.5.3">7.3.5.3 The catan functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
mathematically unbounded along the imaginary axis and in the interval [-pi /2, +pi /2]
along the real axis.
-<a name="7.3.5.4" href="#7.3.5.4"><h5>7.3.5.4 The ccos functions</h5></a>
+<h5><a name="7.3.5.4" href="#7.3.5.4">7.3.5.4 The ccos functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The ccos functions return the complex cosine value.
-<a name="7.3.5.5" href="#7.3.5.5"><h5>7.3.5.5 The csin functions</h5></a>
+<h5><a name="7.3.5.5" href="#7.3.5.5">7.3.5.5 The csin functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The csin functions return the complex sine value.
<!--page 186 -->
-<a name="7.3.5.6" href="#7.3.5.6"><h5>7.3.5.6 The ctan functions</h5></a>
+<h5><a name="7.3.5.6" href="#7.3.5.6">7.3.5.6 The ctan functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The ctan functions return the complex tangent value.
-<a name="7.3.6" href="#7.3.6"><h4>7.3.6 Hyperbolic functions</h4></a>
+<h4><a name="7.3.6" href="#7.3.6">7.3.6 Hyperbolic functions</a></h4>
-<a name="7.3.6.1" href="#7.3.6.1"><h5>7.3.6.1 The cacosh functions</h5></a>
+<h5><a name="7.3.6.1" href="#7.3.6.1">7.3.6.1 The cacosh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
half-strip of non-negative values along the real axis and in the interval [-ipi , +ipi ] along
the imaginary axis.
-<a name="7.3.6.2" href="#7.3.6.2"><h5>7.3.6.2 The casinh functions</h5></a>
+<h5><a name="7.3.6.2" href="#7.3.6.2">7.3.6.2 The casinh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
strip mathematically unbounded along the real axis and in the interval [-ipi /2, +ipi /2]
along the imaginary axis.
-<a name="7.3.6.3" href="#7.3.6.3"><h5>7.3.6.3 The catanh functions</h5></a>
+<h5><a name="7.3.6.3" href="#7.3.6.3">7.3.6.3 The catanh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
strip mathematically unbounded along the real axis and in the interval [-ipi /2, +ipi /2]
along the imaginary axis.
-<a name="7.3.6.4" href="#7.3.6.4"><h5>7.3.6.4 The ccosh functions</h5></a>
+<h5><a name="7.3.6.4" href="#7.3.6.4">7.3.6.4 The ccosh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The ccosh functions return the complex hyperbolic cosine value.
-<a name="7.3.6.5" href="#7.3.6.5"><h5>7.3.6.5 The csinh functions</h5></a>
+<h5><a name="7.3.6.5" href="#7.3.6.5">7.3.6.5 The csinh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<!--page 188 -->
<p><!--para 3 -->
The csinh functions return the complex hyperbolic sine value.
-<a name="7.3.6.6" href="#7.3.6.6"><h5>7.3.6.6 The ctanh functions</h5></a>
+<h5><a name="7.3.6.6" href="#7.3.6.6">7.3.6.6 The ctanh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The ctanh functions return the complex hyperbolic tangent value.
-<a name="7.3.7" href="#7.3.7"><h4>7.3.7 Exponential and logarithmic functions</h4></a>
+<h4><a name="7.3.7" href="#7.3.7">7.3.7 Exponential and logarithmic functions</a></h4>
-<a name="7.3.7.1" href="#7.3.7.1"><h5>7.3.7.1 The cexp functions</h5></a>
+<h5><a name="7.3.7.1" href="#7.3.7.1">7.3.7.1 The cexp functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The cexp functions return the complex base-e exponential value.
-<a name="7.3.7.2" href="#7.3.7.2"><h5>7.3.7.2 The clog functions</h5></a>
+<h5><a name="7.3.7.2" href="#7.3.7.2">7.3.7.2 The clog functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<!--page 189 -->
mathematically unbounded along the real axis and in the interval [-ipi , +ipi ] along the
imaginary axis.
-<a name="7.3.8" href="#7.3.8"><h4>7.3.8 Power and absolute-value functions</h4></a>
+<h4><a name="7.3.8" href="#7.3.8">7.3.8 Power and absolute-value functions</a></h4>
-<a name="7.3.8.1" href="#7.3.8.1"><h5>7.3.8.1 The cabs functions</h5></a>
+<h5><a name="7.3.8.1" href="#7.3.8.1">7.3.8.1 The cabs functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The cabs functions return the complex absolute value.
-<a name="7.3.8.2" href="#7.3.8.2"><h5>7.3.8.2 The cpow functions</h5></a>
+<h5><a name="7.3.8.2" href="#7.3.8.2">7.3.8.2 The cpow functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The cpow functions return the complex power function value.
<!--page 190 -->
-<a name="7.3.8.3" href="#7.3.8.3"><h5>7.3.8.3 The csqrt functions</h5></a>
+<h5><a name="7.3.8.3" href="#7.3.8.3">7.3.8.3 The csqrt functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The csqrt functions return the complex square root value, in the range of the right half-
plane (including the imaginary axis).
-<a name="7.3.9" href="#7.3.9"><h4>7.3.9 Manipulation functions</h4></a>
+<h4><a name="7.3.9" href="#7.3.9">7.3.9 Manipulation functions</a></h4>
-<a name="7.3.9.1" href="#7.3.9.1"><h5>7.3.9.1 The carg functions</h5></a>
+<h5><a name="7.3.9.1" href="#7.3.9.1">7.3.9.1 The carg functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The carg functions return the value of the argument in the interval [-pi , +pi ].
-<a name="7.3.9.2" href="#7.3.9.2"><h5>7.3.9.2 The cimag functions</h5></a>
+<h5><a name="7.3.9.2" href="#7.3.9.2">7.3.9.2 The cimag functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<!--page 191 -->
<p><small><a name="note170" href="#note170">170)</a> For a variable z of complex type, z == creal(z) + cimag(z)*I.
</small>
-<a name="7.3.9.3" href="#7.3.9.3"><h5>7.3.9.3 The conj functions</h5></a>
+<h5><a name="7.3.9.3" href="#7.3.9.3">7.3.9.3 The conj functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The conj functions return the complex conjugate value.
-<a name="7.3.9.4" href="#7.3.9.4"><h5>7.3.9.4 The cproj functions</h5></a>
+<h5><a name="7.3.9.4" href="#7.3.9.4">7.3.9.4 The cproj functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 192 -->
-<a name="7.3.9.5" href="#7.3.9.5"><h5>7.3.9.5 The creal functions</h5></a>
+<h5><a name="7.3.9.5" href="#7.3.9.5">7.3.9.5 The creal functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note171" href="#note171">171)</a> For a variable z of complex type, z == creal(z) + cimag(z)*I.
</small>
-<a name="7.4" href="#7.4"><h3>7.4 Character handling <ctype.h></h3></a>
+<h3><a name="7.4" href="#7.4">7.4 Character handling <ctype.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.4"><ctype.h></a> declares several functions useful for classifying and mapping
characters.<sup><a href="#note172"><b>172)</b></a></sup> In all cases the argument is an int, the value of which shall be
values lie from 0 (NUL) through 0x1F (US), and the character 0x7F (DEL).
</small>
-<a name="7.4.1" href="#7.4.1"><h4>7.4.1 Character classification functions</h4></a>
+<h4><a name="7.4.1" href="#7.4.1">7.4.1 Character classification functions</a></h4>
<p><!--para 1 -->
The functions in this subclause return nonzero (true) if and only if the value of the
argument c conforms to that in the description of the function.
-<a name="7.4.1.1" href="#7.4.1.1"><h5>7.4.1.1 The isalnum function</h5></a>
+<h5><a name="7.4.1.1" href="#7.4.1.1">7.4.1.1 The isalnum function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The isalnum function tests for any character for which isalpha or isdigit is true.
-<a name="7.4.1.2" href="#7.4.1.2"><h5>7.4.1.2 The isalpha function</h5></a>
+<h5><a name="7.4.1.2" href="#7.4.1.2">7.4.1.2 The isalpha function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
characters; all four combinations are possible.
</small>
-<a name="7.4.1.3" href="#7.4.1.3"><h5>7.4.1.3 The isblank function</h5></a>
+<h5><a name="7.4.1.3" href="#7.4.1.3">7.4.1.3 The isblank function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
space (' '), and horizontal tab ('\t'). In the "C" locale, isblank returns true only
for the standard blank characters.
-<a name="7.4.1.4" href="#7.4.1.4"><h5>7.4.1.4 The iscntrl function</h5></a>
+<h5><a name="7.4.1.4" href="#7.4.1.4">7.4.1.4 The iscntrl function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The iscntrl function tests for any control character.
-<a name="7.4.1.5" href="#7.4.1.5"><h5>7.4.1.5 The isdigit function</h5></a>
+<h5><a name="7.4.1.5" href="#7.4.1.5">7.4.1.5 The isdigit function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The isdigit function tests for any decimal-digit character (as defined in <a href="#5.2.1">5.2.1</a>).
-<a name="7.4.1.6" href="#7.4.1.6"><h5>7.4.1.6 The isgraph function</h5></a>
+<h5><a name="7.4.1.6" href="#7.4.1.6">7.4.1.6 The isgraph function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The isgraph function tests for any printing character except space (' ').
-<a name="7.4.1.7" href="#7.4.1.7"><h5>7.4.1.7 The islower function</h5></a>
+<h5><a name="7.4.1.7" href="#7.4.1.7">7.4.1.7 The islower function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
isspace is true. In the "C" locale, islower returns true only for the lowercase
letters (as defined in <a href="#5.2.1">5.2.1</a>).
-<a name="7.4.1.8" href="#7.4.1.8"><h5>7.4.1.8 The isprint function</h5></a>
+<h5><a name="7.4.1.8" href="#7.4.1.8">7.4.1.8 The isprint function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The isprint function tests for any printing character including space (' ').
-<a name="7.4.1.9" href="#7.4.1.9"><h5>7.4.1.9 The ispunct function</h5></a>
+<h5><a name="7.4.1.9" href="#7.4.1.9">7.4.1.9 The ispunct function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
locale, ispunct returns true for every printing character for which neither isspace
nor isalnum is true.
-<a name="7.4.1.10" href="#7.4.1.10"><h5>7.4.1.10 The isspace function</h5></a>
+<h5><a name="7.4.1.10" href="#7.4.1.10">7.4.1.10 The isspace function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
('\n'), carriage return ('\r'), horizontal tab ('\t'), and vertical tab ('\v'). In the
"C" locale, isspace returns true only for the standard white-space characters.
-<a name="7.4.1.11" href="#7.4.1.11"><h5>7.4.1.11 The isupper function</h5></a>
+<h5><a name="7.4.1.11" href="#7.4.1.11">7.4.1.11 The isupper function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
isspace is true. In the "C" locale, isupper returns true only for the uppercase
letters (as defined in <a href="#5.2.1">5.2.1</a>).
-<a name="7.4.1.12" href="#7.4.1.12"><h5>7.4.1.12 The isxdigit function</h5></a>
+<h5><a name="7.4.1.12" href="#7.4.1.12">7.4.1.12 The isxdigit function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The isxdigit function tests for any hexadecimal-digit character (as defined in <a href="#6.4.4.1">6.4.4.1</a>).
-<a name="7.4.2" href="#7.4.2"><h4>7.4.2 Character case mapping functions</h4></a>
+<h4><a name="7.4.2" href="#7.4.2">7.4.2 Character case mapping functions</a></h4>
-<a name="7.4.2.1" href="#7.4.2.1"><h5>7.4.2.1 The tolower function</h5></a>
+<h5><a name="7.4.2.1" href="#7.4.2.1">7.4.2.1 The tolower function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
for any given locale); otherwise, the argument is returned unchanged.
<!--page 197 -->
-<a name="7.4.2.2" href="#7.4.2.2"><h5>7.4.2.2 The toupper function</h5></a>
+<h5><a name="7.4.2.2" href="#7.4.2.2">7.4.2.2 The toupper function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
for any given locale); otherwise, the argument is returned unchanged.
<!--page 198 -->
-<a name="7.5" href="#7.5"><h3>7.5 Errors <errno.h></h3></a>
+<h3><a name="7.5" href="#7.5">7.5 Errors <errno.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.5"><errno.h></a> defines several macros, all relating to the reporting of error
conditions.
<p><small><a name="note177" href="#note177">177)</a> See ''future library directions'' (<a href="#7.26.3">7.26.3</a>).
</small>
-<a name="7.6" href="#7.6"><h3>7.6 Floating-point environment <fenv.h></h3></a>
+<h3><a name="7.6" href="#7.6">7.6 Floating-point environment <fenv.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.6"><fenv.h></a> declares two types and several macros and functions to provide
access to the floating-point environment. The floating-point environment refers
<pre>
FE_DFL_ENV</pre>
represents the default floating-point environment -- the one installed at program startup
-<ul>
-<li> and has type ''pointer to const-qualified fenv_t''. It can be used as an argument to
-</ul>
+ -- and has type ''pointer to const-qualified fenv_t''. It can be used as an argument to
<a href="#7.6"><fenv.h></a> functions that manage the floating-point environment.
<p><!--para 9 -->
Additional implementation-defined environments, with macro definitions beginning with
FLT_ROUNDS, they are not required to do so.
</small>
-<a name="7.6.1" href="#7.6.1"><h4>7.6.1 The FENV_ACCESS pragma</h4></a>
+<h4><a name="7.6.1" href="#7.6.1">7.6.1 The FENV_ACCESS pragma</a></h4>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
''off'', just one evaluation of x + 1 would suffice.
</small>
-<a name="7.6.2" href="#7.6.2"><h4>7.6.2 Floating-point exceptions</h4></a>
+<h4><a name="7.6.2" href="#7.6.2">7.6.2 Floating-point exceptions</a></h4>
<p><!--para 1 -->
The following functions provide access to the floating-point status flags.<sup><a href="#note186"><b>186)</b></a></sup> The int
input argument for the functions represents a subset of floating-point exceptions, and can
content of flags.
</small>
-<a name="7.6.2.1" href="#7.6.2.1"><h5>7.6.2.1 The feclearexcept function</h5></a>
+<h5><a name="7.6.2.1" href="#7.6.2.1">7.6.2.1 The feclearexcept function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 203 -->
-<a name="7.6.2.2" href="#7.6.2.2"><h5>7.6.2.2 The fegetexceptflag function</h5></a>
+<h5><a name="7.6.2.2" href="#7.6.2.2">7.6.2.2 The fegetexceptflag function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The fegetexceptflag function returns zero if the representation was successfully
stored. Otherwise, it returns a nonzero value.
-<a name="7.6.2.3" href="#7.6.2.3"><h5>7.6.2.3 The feraiseexcept function</h5></a>
+<h5><a name="7.6.2.3" href="#7.6.2.3">7.6.2.3 The feraiseexcept function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
in <a href="#F.7.6">F.7.6</a> is in the same spirit.
</small>
-<a name="7.6.2.4" href="#7.6.2.4"><h5>7.6.2.4 The fesetexceptflag function</h5></a>
+<h5><a name="7.6.2.4" href="#7.6.2.4">7.6.2.4 The fesetexceptflag function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
all the specified flags were successfully set to the appropriate state. Otherwise, it returns
a nonzero value.
-<a name="7.6.2.5" href="#7.6.2.5"><h5>7.6.2.5 The fetestexcept function</h5></a>
+<h5><a name="7.6.2.5" href="#7.6.2.5">7.6.2.5 The fetestexcept function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note188" href="#note188">188)</a> This mechanism allows testing several floating-point exceptions with just one function call.
</small>
-<a name="7.6.3" href="#7.6.3"><h4>7.6.3 Rounding</h4></a>
+<h4><a name="7.6.3" href="#7.6.3">7.6.3 Rounding</a></h4>
<p><!--para 1 -->
The fegetround and fesetround functions provide control of rounding direction
modes.
-<a name="7.6.3.1" href="#7.6.3.1"><h5>7.6.3.1 The fegetround function</h5></a>
+<h5><a name="7.6.3.1" href="#7.6.3.1">7.6.3.1 The fegetround function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
representing the current rounding direction or a negative value if there is no such
rounding direction macro or the current rounding direction is not determinable.
-<a name="7.6.3.2" href="#7.6.3.2"><h5>7.6.3.2 The fesetround function</h5></a>
+<h5><a name="7.6.3.2" href="#7.6.3.2">7.6.3.2 The fesetround function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
}</pre>
-<a name="7.6.4" href="#7.6.4"><h4>7.6.4 Environment</h4></a>
+<h4><a name="7.6.4" href="#7.6.4">7.6.4 Environment</a></h4>
<p><!--para 1 -->
The functions in this section manage the floating-point environment -- status flags and
control modes -- as one entity.
-<a name="7.6.4.1" href="#7.6.4.1"><h5>7.6.4.1 The fegetenv function</h5></a>
+<h5><a name="7.6.4.1" href="#7.6.4.1">7.6.4.1 The fegetenv function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The fegetenv function returns zero if the environment was successfully stored.
Otherwise, it returns a nonzero value.
-<a name="7.6.4.2" href="#7.6.4.2"><h5>7.6.4.2 The feholdexcept function</h5></a>
+<h5><a name="7.6.4.2" href="#7.6.4.2">7.6.4.2 The feholdexcept function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
function to write routines that hide spurious floating-point exceptions from their callers.
</small>
-<a name="7.6.4.3" href="#7.6.4.3"><h5>7.6.4.3 The fesetenv function</h5></a>
+<h5><a name="7.6.4.3" href="#7.6.4.3">7.6.4.3 The fesetenv function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The fesetenv function returns zero if the environment was successfully established.
Otherwise, it returns a nonzero value.
-<a name="7.6.4.4" href="#7.6.4.4"><h5>7.6.4.4 The feupdateenv function</h5></a>
+<h5><a name="7.6.4.4" href="#7.6.4.4">7.6.4.4 The feupdateenv function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
return result;
}</pre>
-<a name="7.7" href="#7.7"><h3>7.7 Characteristics of floating types <float.h></h3></a>
+<h3><a name="7.7" href="#7.7">7.7 Characteristics of floating types <float.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.7"><float.h></a> defines several macros that expand to various limits and
parameters of the standard floating-point types.
in <a href="#5.2.4.2.2">5.2.4.2.2</a>.
<!--page 210 -->
-<a name="7.8" href="#7.8"><h3>7.8 Format conversion of integer types <inttypes.h></h3></a>
+<h3><a name="7.8" href="#7.8">7.8 Format conversion of integer types <inttypes.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.8"><inttypes.h></a> includes the header <a href="#7.18"><stdint.h></a> and extends it with
additional facilities provided by hosted implementations.
<p><small><a name="note190" href="#note190">190)</a> See ''future library directions'' (<a href="#7.26.4">7.26.4</a>).
</small>
-<a name="7.8.1" href="#7.8.1"><h4>7.8.1 Macros for format specifiers</h4></a>
+<h4><a name="7.8.1" href="#7.8.1">7.8.1 Macros for format specifiers</a></h4>
<p><!--para 1 -->
Each of the following object-like macros<sup><a href="#note191"><b>191)</b></a></sup> expands to a character string literal
containing a conversion specifier, possibly modified by a length modifier, suitable for use
same.
</small>
-<a name="7.8.2" href="#7.8.2"><h4>7.8.2 Functions for greatest-width integer types</h4></a>
+<h4><a name="7.8.2" href="#7.8.2">7.8.2 Functions for greatest-width integer types</a></h4>
-<a name="7.8.2.1" href="#7.8.2.1"><h5>7.8.2.1 The imaxabs function</h5></a>
+<h5><a name="7.8.2.1" href="#7.8.2.1">7.8.2.1 The imaxabs function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note193" href="#note193">193)</a> The absolute value of the most negative number cannot be represented in two's complement.
</small>
-<a name="7.8.2.2" href="#7.8.2.2"><h5>7.8.2.2 The imaxdiv function</h5></a>
+<h5><a name="7.8.2.2" href="#7.8.2.2">7.8.2.2 The imaxdiv function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
quot (the quotient) and rem (the remainder), each of which has type intmax_t. If
either part of the result cannot be represented, the behavior is undefined.
-<a name="7.8.2.3" href="#7.8.2.3"><h5>7.8.2.3 The strtoimax and strtoumax functions</h5></a>
+<h5><a name="7.8.2.3" href="#7.8.2.3">7.8.2.3 The strtoimax and strtoumax functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
(<a href="#7.20.1.4">7.20.1.4</a>).
<!--page 213 -->
-<a name="7.8.2.4" href="#7.8.2.4"><h5>7.8.2.4 The wcstoimax and wcstoumax functions</h5></a>
+<h5><a name="7.8.2.4" href="#7.8.2.4">7.8.2.4 The wcstoimax and wcstoumax functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
(<a href="#7.24.4.1.2">7.24.4.1.2</a>).
<!--page 214 -->
-<a name="7.9" href="#7.9"><h3>7.9 Alternative spellings <iso646.h></h3></a>
+<h3><a name="7.9" href="#7.9">7.9 Alternative spellings <iso646.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.9"><iso646.h></a> defines the following eleven macros (on the left) that expand
to the corresponding tokens (on the right):
xor ^
xor_eq ^=</pre>
-<a name="7.10" href="#7.10"><h3>7.10 Sizes of integer types <limits.h></h3></a>
+<h3><a name="7.10" href="#7.10">7.10 Sizes of integer types <limits.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.10"><limits.h></a> defines several macros that expand to various limits and
parameters of the standard integer types.
in <a href="#5.2.4.2.1">5.2.4.2.1</a>.
<!--page 216 -->
-<a name="7.11" href="#7.11"><h3>7.11 Localization <locale.h></h3></a>
+<h3><a name="7.11" href="#7.11">7.11 Localization <locale.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.11"><locale.h></a> declares two functions, one type, and defines several macros.
<p><!--para 2 -->
<p><small><a name="note195" href="#note195">195)</a> See ''future library directions'' (<a href="#7.26.5">7.26.5</a>).
</small>
-<a name="7.11.1" href="#7.11.1"><h4>7.11.1 Locale control</h4></a>
+<h4><a name="7.11.1" href="#7.11.1">7.11.1 Locale control</a></h4>
-<a name="7.11.1.1" href="#7.11.1.1"><h5>7.11.1.1 The setlocale function</h5></a>
+<h5><a name="7.11.1.1" href="#7.11.1.1">7.11.1.1 The setlocale function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
locale when category has the value LC_ALL.
</small>
-<a name="7.11.2" href="#7.11.2"><h4>7.11.2 Numeric formatting convention inquiry</h4></a>
+<h4><a name="7.11.2" href="#7.11.2">7.11.2 Numeric formatting convention inquiry</a></h4>
-<a name="7.11.2.1" href="#7.11.2.1"><h5>7.11.2.1 The localeconv function</h5></a>
+<h5><a name="7.11.2.1" href="#7.11.2.1">7.11.2.1 The localeconv function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
strings shall start and end in the initial shift state. The members with type char are
nonnegative numbers, any of which can be CHAR_MAX to indicate that the value is not
available in the current locale. The members include the following:
- char *decimal_point
-<pre>
- The decimal-point character used to format nonmonetary quantities.</pre>
- char *thousands_sep
-<pre>
+<dl>
+<dt> char *decimal_point
+<dd>
+ The decimal-point character used to format nonmonetary quantities.
+<dt> char *thousands_sep
+<dd>
The character used to separate groups of digits before the decimal-point
- character in formatted nonmonetary quantities.</pre>
- char *grouping
-<pre>
+ character in formatted nonmonetary quantities.
+<dt> char *grouping
+<dd>
A string whose elements indicate the size of each group of digits in
- formatted nonmonetary quantities.</pre>
- char *mon_decimal_point
-<pre>
- The decimal-point used to format monetary quantities.</pre>
- char *mon_thousands_sep
-<pre>
+ formatted nonmonetary quantities.
+<dt> char *mon_decimal_point
+<dd>
+ The decimal-point used to format monetary quantities.
+<dt> char *mon_thousands_sep
+<dd>
The separator for groups of digits before the decimal-point in formatted
- monetary quantities.</pre>
- char *mon_grouping
-<pre>
+ monetary quantities.
+<dt> char *mon_grouping
+<dd>
A string whose elements indicate the size of each group of digits in
- formatted monetary quantities.</pre>
- char *positive_sign
-<pre>
+ formatted monetary quantities.
+<dt> char *positive_sign
+<dd>
The string used to indicate a nonnegative-valued formatted monetary
- quantity.</pre>
- char *negative_sign
-<pre>
- The string used to indicate a negative-valued formatted monetary quantity.</pre>
- char *currency_symbol
-<pre>
- The local currency symbol applicable to the current locale.</pre>
- char frac_digits
-<pre>
+ quantity.
+<dt> char *negative_sign
+<dd>
+ The string used to indicate a negative-valued formatted monetary quantity.
+<dt> char *currency_symbol
+<dd>
+ The local currency symbol applicable to the current locale.
+<dt> char frac_digits
+<dd>
The number of fractional digits (those after the decimal-point) to be
- displayed in a locally formatted monetary quantity.</pre>
- char p_cs_precedes
-<pre>
+ displayed in a locally formatted monetary quantity.
+<dt> char p_cs_precedes
+<dd>
Set to 1 or 0 if the currency_symbol respectively precedes or
- succeeds the value for a nonnegative locally formatted monetary quantity.</pre>
- char n_cs_precedes
+ succeeds the value for a nonnegative locally formatted monetary quantity.
+<dt> char n_cs_precedes
<!--page 220 -->
-<pre>
+<dd>
Set to 1 or 0 if the currency_symbol respectively precedes or
- succeeds the value for a negative locally formatted monetary quantity.</pre>
- char p_sep_by_space
-<pre>
+ succeeds the value for a negative locally formatted monetary quantity.
+<dt> char p_sep_by_space
+<dd>
Set to a value indicating the separation of the currency_symbol, the
sign string, and the value for a nonnegative locally formatted monetary
- quantity.</pre>
- char n_sep_by_space
-<pre>
+ quantity.
+<dt> char n_sep_by_space
+<dd>
Set to a value indicating the separation of the currency_symbol, the
sign string, and the value for a negative locally formatted monetary
- quantity.</pre>
- char p_sign_posn
-<pre>
+ quantity.
+<dt> char p_sign_posn
+<dd>
Set to a value indicating the positioning of the positive_sign for a
- nonnegative locally formatted monetary quantity.</pre>
- char n_sign_posn
-<pre>
+ nonnegative locally formatted monetary quantity.
+<dt> char n_sign_posn
+<dd>
Set to a value indicating the positioning of the negative_sign for a
- negative locally formatted monetary quantity.</pre>
- char *int_curr_symbol
-<pre>
+ negative locally formatted monetary quantity.
+<dt> char *int_curr_symbol
+<dd>
The international currency symbol applicable to the current locale. The
first three characters contain the alphabetic international currency symbol
in accordance with those specified in ISO 4217. The fourth character
(immediately preceding the null character) is the character used to separate
- the international currency symbol from the monetary quantity.</pre>
- char int_frac_digits
-<pre>
+ the international currency symbol from the monetary quantity.
+<dt> char int_frac_digits
+<dd>
The number of fractional digits (those after the decimal-point) to be
- displayed in an internationally formatted monetary quantity.</pre>
- char int_p_cs_precedes
-<pre>
+ displayed in an internationally formatted monetary quantity.
+<dt> char int_p_cs_precedes
+<dd>
Set to 1 or 0 if the int_curr_symbol respectively precedes or
succeeds the value for a nonnegative internationally formatted monetary
- quantity.</pre>
- char int_n_cs_precedes
-<pre>
+ quantity.
+<dt> char int_n_cs_precedes
+<dd>
Set to 1 or 0 if the int_curr_symbol respectively precedes or
succeeds the value for a negative internationally formatted monetary
- quantity.</pre>
- char int_p_sep_by_space
+ quantity.
+<dt> char int_p_sep_by_space
<!--page 221 -->
-<pre>
+<dd>
Set to a value indicating the separation of the int_curr_symbol, the
sign string, and the value for a nonnegative internationally formatted
- monetary quantity.</pre>
- char int_n_sep_by_space
-<pre>
+ monetary quantity.
+<dt> char int_n_sep_by_space
+<dd>
Set to a value indicating the separation of the int_curr_symbol, the
sign string, and the value for a negative internationally formatted monetary
- quantity.</pre>
- char int_p_sign_posn
-<pre>
+ quantity.
+<dt> char int_p_sign_posn
+<dd>
Set to a value indicating the positioning of the positive_sign for a
- nonnegative internationally formatted monetary quantity.</pre>
- char int_n_sign_posn
-<p><!--para 4 -->
-<pre>
+ nonnegative internationally formatted monetary quantity.
+<dt> char int_n_sign_posn
+<dd>
Set to a value indicating the positioning of the negative_sign for a
- negative internationally formatted monetary quantity.</pre>
+ negative internationally formatted monetary quantity.
+</dl>
+<p><!--para 4 -->
The elements of grouping and mon_grouping are interpreted according to the
following:
- CHAR_MAX No further grouping is to be performed.
- 0 The previous element is to be repeatedly used for the remainder of the
-<pre>
- digits.</pre>
- other The integer value is the number of digits that compose the current group.
-<p><!--para 5 -->
-<pre>
+<dl>
+<dt> CHAR_MAX <dd>No further grouping is to be performed.
+<dt> 0 <dd>The previous element is to be repeatedly used for the remainder of the
+ digits.
+<dt> other <dd>The integer value is the number of digits that compose the current group.
The next element is examined to determine the size of the next group of
- digits before the current group.</pre>
+ digits before the current group.
+</dl>
+<p><!--para 5 -->
The values of p_sep_by_space, n_sep_by_space, int_p_sep_by_space,
and int_n_sep_by_space are interpreted according to the following:
- 0 No space separates the currency symbol and value.
- 1 If the currency symbol and sign string are adjacent, a space separates them from the
-<pre>
- value; otherwise, a space separates the currency symbol from the value.</pre>
- 2 If the currency symbol and sign string are adjacent, a space separates them;
-<pre>
- otherwise, a space separates the sign string from the value.</pre>
+<dl>
+<dt> 0 <dd>No space separates the currency symbol and value.
+<dt> 1 <dd>If the currency symbol and sign string are adjacent, a space separates them from the
+ value; otherwise, a space separates the currency symbol from the value.
+<dt> 2 <dd>If the currency symbol and sign string are adjacent, a space separates them;
+ otherwise, a space separates the sign string from the value.
+</dl>
For int_p_sep_by_space and int_n_sep_by_space, the fourth character of
int_curr_symbol is used instead of a space.
<p><!--para 6 -->
The values of p_sign_posn, n_sign_posn, int_p_sign_posn, and
int_n_sign_posn are interpreted according to the following:
- 0 Parentheses surround the quantity and currency symbol.
- 1 The sign string precedes the quantity and currency symbol.
- 2 The sign string succeeds the quantity and currency symbol.
- 3 The sign string immediately precedes the currency symbol.
- 4 The sign string immediately succeeds the currency symbol.
+<dl>
+<dt> 0 <dd>Parentheses surround the quantity and currency symbol.
+<dt> 1 <dd>The sign string precedes the quantity and currency symbol.
+<dt> 2 <dd>The sign string succeeds the quantity and currency symbol.
+<dt> 3 <dd>The sign string immediately precedes the currency symbol.
+<dt> 4 <dd>The sign string immediately succeeds the currency symbol.
+</dl>
<!--page 222 -->
<p><!--para 7 -->
The implementation shall behave as if no library function calls the localeconv
EXAMPLE 1 The following table illustrates rules which may well be used by four countries to format
monetary quantities.
<pre>
- Local format International format</pre>
+ Local format International format
- Country Positive Negative Positive Negative
+ Country Positive Negative Positive Negative
Country1 1.234,56 mk -1.234,56 mk FIM 1.234,56 FIM -1.234,56
Country2 L.1.234 -L.1.234 ITL 1.234 -ITL 1.234
- Country3 fl. 1.234,56 fl. -1.234,56 NLG 1.234,56 NLG -1.234,56
+ Country3 fl. 1.234,56 fl. -1.234,56 NLG 1.234,56 NLG -1.234,56
Country4 SFrs.1,234.56 SFrs.1,234.56C CHF 1,234.56 CHF 1,234.56C
+</pre>
<p><!--para 10 -->
For these four countries, the respective values for the monetary members of the structure returned by
localeconv could be:
<pre>
- Country1 Country2 Country3 Country4</pre>
+ Country1 Country2 Country3 Country4
mon_decimal_point "," "" "," "."
mon_thousands_sep "." "." "." ","
int_n_sep_by_space 2 1 2 1
int_p_sign_posn 1 1 1 1
int_n_sign_posn 4 1 4 2
+</pre>
<!--page 223 -->
<p><!--para 11 -->
EXAMPLE 2 The following table illustrates how the cs_precedes, sep_by_space, and sign_posn members
affect the formatted value.
<pre>
- p_sep_by_space</pre>
-
- p_cs_precedes p_sign_posn 0 1 2
-
-<pre>
- 0 0 (<a href="#1.25">1.25</a>$) (<a href="#1.25">1.25</a> $) (<a href="#1.25">1.25</a>$)
- 1 +1.25$ +1.25 $ + <a href="#1.25">1.25</a>$
- 2 <a href="#1.25">1.25</a>$+ <a href="#1.25">1.25</a> $+ <a href="#1.25">1.25</a>$ +
- 3 <a href="#1.25">1.25</a>+$ <a href="#1.25">1.25</a> +$ <a href="#1.25">1.25</a>+ $
- 4 <a href="#1.25">1.25</a>$+ <a href="#1.25">1.25</a> $+ <a href="#1.25">1.25</a>$ +</pre>
-
-<!--page 224 -->
-<pre>
- 1 0 ($1.25) ($ <a href="#1.25">1.25</a>) ($1.25)
- 1 +$1.25 +$ <a href="#1.25">1.25</a> + $1.25
- 2 $1.25+ $ <a href="#1.25">1.25</a>+ $1.25 +
- 3 +$1.25 +$ <a href="#1.25">1.25</a> + $1.25
- 4 $+1.25 $+ <a href="#1.25">1.25</a> $ +1.25</pre>
+ p_sep_by_space
+ p_cs_precedes p_sign_posn 0 1 2
+
+ 0 0 (<a href="#1.25">1.25</a>$) (<a href="#1.25">1.25</a> $) (<a href="#1.25">1.25</a>$)
+ 1 +1.25$ +1.25 $ + <a href="#1.25">1.25</a>$
+ 2 <a href="#1.25">1.25</a>$+ <a href="#1.25">1.25</a> $+ <a href="#1.25">1.25</a>$ +
+ 3 <a href="#1.25">1.25</a>+$ <a href="#1.25">1.25</a> +$ <a href="#1.25">1.25</a>+ $
+ 4 <a href="#1.25">1.25</a>$+ <a href="#1.25">1.25</a> $+ <a href="#1.25">1.25</a>$ +
-<a name="7.12" href="#7.12"><h3>7.12 Mathematics <math.h></h3></a>
+ 1 0 ($1.25) ($ <a href="#1.25">1.25</a>) ($1.25)
+ 1 +$1.25 +$ <a href="#1.25">1.25</a> + $1.25
+ 2 $1.25+ $ <a href="#1.25">1.25</a>+ $1.25 +
+ 3 +$1.25 +$ <a href="#1.25">1.25</a> + $1.25
+ 4 $+1.25 $+ <a href="#1.25">1.25</a> $ +1.25</pre>
+
+<!--page 224 -->
+<h3><a name="7.12" href="#7.12">7.12 Mathematics <math.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.12"><math.h></a> declares two types and many mathematical functions and defines
several macros. Most synopses specify a family of functions consisting of a principal
substantially slower.
</small>
-<a name="7.12.1" href="#7.12.1"><h4>7.12.1 Treatment of error conditions</h4></a>
+<h4><a name="7.12.1" href="#7.12.1">7.12.1 Treatment of error conditions</a></h4>
<p><!--para 1 -->
The behavior of each of the functions in <a href="#7.12"><math.h></a> is specified for all representable
values of its input arguments, except where stated otherwise. Each function shall execute
also ''flush-to-zero'' underflow.
</small>
-<a name="7.12.2" href="#7.12.2"><h4>7.12.2 The FP_CONTRACT pragma</h4></a>
+<h4><a name="7.12.2" href="#7.12.2">7.12.2 The FP_CONTRACT pragma</a></h4>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 228 -->
-<a name="7.12.3" href="#7.12.3"><h4>7.12.3 Classification macros</h4></a>
+<h4><a name="7.12.3" href="#7.12.3">7.12.3 Classification macros</a></h4>
<p><!--para 1 -->
In the synopses in this subclause, real-floating indicates that the argument shall be an
expression of real floating type.
-<a name="7.12.3.1" href="#7.12.3.1"><h5>7.12.3.1 The fpclassify macro</h5></a>
+<h5><a name="7.12.3.1" href="#7.12.3.1">7.12.3.1 The fpclassify macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
become subnormal when converted to double, and zero when converted to float.
</small>
-<a name="7.12.3.2" href="#7.12.3.2"><h5>7.12.3.2 The isfinite macro</h5></a>
+<h5><a name="7.12.3.2" href="#7.12.3.2">7.12.3.2 The isfinite macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The isfinite macro returns a nonzero value if and only if its argument has a finite
value.
-<a name="7.12.3.3" href="#7.12.3.3"><h5>7.12.3.3 The isinf macro</h5></a>
+<h5><a name="7.12.3.3" href="#7.12.3.3">7.12.3.3 The isinf macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The isinf macro returns a nonzero value if and only if its argument has an infinite
value.
-<a name="7.12.3.4" href="#7.12.3.4"><h5>7.12.3.4 The isnan macro</h5></a>
+<h5><a name="7.12.3.4" href="#7.12.3.4">7.12.3.4 The isnan macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
NaNs in the evaluation type but not in the semantic type.
</small>
-<a name="7.12.3.5" href="#7.12.3.5"><h5>7.12.3.5 The isnormal macro</h5></a>
+<h5><a name="7.12.3.5" href="#7.12.3.5">7.12.3.5 The isnormal macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The isnormal macro returns a nonzero value if and only if its argument has a normal
value.
-<a name="7.12.3.6" href="#7.12.3.6"><h5>7.12.3.6 The signbit macro</h5></a>
+<h5><a name="7.12.3.6" href="#7.12.3.6">7.12.3.6 The signbit macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
unsigned, it is treated as positive.
</small>
-<a name="7.12.4" href="#7.12.4"><h4>7.12.4 Trigonometric functions</h4></a>
+<h4><a name="7.12.4" href="#7.12.4">7.12.4 Trigonometric functions</a></h4>
-<a name="7.12.4.1" href="#7.12.4.1"><h5>7.12.4.1 The acos functions</h5></a>
+<h5><a name="7.12.4.1" href="#7.12.4.1">7.12.4.1 The acos functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 231 -->
-<a name="7.12.4.2" href="#7.12.4.2"><h5>7.12.4.2 The asin functions</h5></a>
+<h5><a name="7.12.4.2" href="#7.12.4.2">7.12.4.2 The asin functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The asin functions return arcsin x in the interval [-pi /2, +pi /2] radians.
-<a name="7.12.4.3" href="#7.12.4.3"><h5>7.12.4.3 The atan functions</h5></a>
+<h5><a name="7.12.4.3" href="#7.12.4.3">7.12.4.3 The atan functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The atan functions return arctan x in the interval [-pi /2, +pi /2] radians.
-<a name="7.12.4.4" href="#7.12.4.4"><h5>7.12.4.4 The atan2 functions</h5></a>
+<h5><a name="7.12.4.4" href="#7.12.4.4">7.12.4.4 The atan2 functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The atan2 functions return arctan y/x in the interval [-pi , +pi ] radians.
<!--page 232 -->
-<a name="7.12.4.5" href="#7.12.4.5"><h5>7.12.4.5 The cos functions</h5></a>
+<h5><a name="7.12.4.5" href="#7.12.4.5">7.12.4.5 The cos functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The cos functions return cos x.
-<a name="7.12.4.6" href="#7.12.4.6"><h5>7.12.4.6 The sin functions</h5></a>
+<h5><a name="7.12.4.6" href="#7.12.4.6">7.12.4.6 The sin functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The sin functions return sin x.
-<a name="7.12.4.7" href="#7.12.4.7"><h5>7.12.4.7 The tan functions</h5></a>
+<h5><a name="7.12.4.7" href="#7.12.4.7">7.12.4.7 The tan functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The tan functions return tan x.
<!--page 233 -->
-<a name="7.12.5" href="#7.12.5"><h4>7.12.5 Hyperbolic functions</h4></a>
+<h4><a name="7.12.5" href="#7.12.5">7.12.5 Hyperbolic functions</a></h4>
-<a name="7.12.5.1" href="#7.12.5.1"><h5>7.12.5.1 The acosh functions</h5></a>
+<h5><a name="7.12.5.1" href="#7.12.5.1">7.12.5.1 The acosh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The acosh functions return arcosh x in the interval [0, +(inf)].
-<a name="7.12.5.2" href="#7.12.5.2"><h5>7.12.5.2 The asinh functions</h5></a>
+<h5><a name="7.12.5.2" href="#7.12.5.2">7.12.5.2 The asinh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The asinh functions return arsinh x.
-<a name="7.12.5.3" href="#7.12.5.3"><h5>7.12.5.3 The atanh functions</h5></a>
+<h5><a name="7.12.5.3" href="#7.12.5.3">7.12.5.3 The atanh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The atanh functions return artanh x.
-<a name="7.12.5.4" href="#7.12.5.4"><h5>7.12.5.4 The cosh functions</h5></a>
+<h5><a name="7.12.5.4" href="#7.12.5.4">7.12.5.4 The cosh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The cosh functions return cosh x.
-<a name="7.12.5.5" href="#7.12.5.5"><h5>7.12.5.5 The sinh functions</h5></a>
+<h5><a name="7.12.5.5" href="#7.12.5.5">7.12.5.5 The sinh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The sinh functions return sinh x.
-<a name="7.12.5.6" href="#7.12.5.6"><h5>7.12.5.6 The tanh functions</h5></a>
+<h5><a name="7.12.5.6" href="#7.12.5.6">7.12.5.6 The tanh functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The tanh functions return tanh x.
-<a name="7.12.6" href="#7.12.6"><h4>7.12.6 Exponential and logarithmic functions</h4></a>
+<h4><a name="7.12.6" href="#7.12.6">7.12.6 Exponential and logarithmic functions</a></h4>
-<a name="7.12.6.1" href="#7.12.6.1"><h5>7.12.6.1 The exp functions</h5></a>
+<h5><a name="7.12.6.1" href="#7.12.6.1">7.12.6.1 The exp functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
magnitude of x is too large.
<h6>Returns</h6>
<p><!--para 3 -->
- The exp functions return ex .
+ The exp functions return e<sup>x</sup>.
-<a name="7.12.6.2" href="#7.12.6.2"><h5>7.12.6.2 The exp2 functions</h5></a>
+<h5><a name="7.12.6.2" href="#7.12.6.2">7.12.6.2 The exp2 functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
magnitude of x is too large.
<h6>Returns</h6>
<p><!--para 3 -->
- The exp2 functions return 2x .
+ The exp2 functions return 2<sup>x</sup>.
-<a name="7.12.6.3" href="#7.12.6.3"><h5>7.12.6.3 The expm1 functions</h5></a>
+<h5><a name="7.12.6.3" href="#7.12.6.3">7.12.6.3 The expm1 functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<!--page 236 -->
error occurs if x is too large.<sup><a href="#note208"><b>208)</b></a></sup>
<h6>Returns</h6>
<p><!--para 3 -->
- The expm1 functions return ex - 1.
+ The expm1 functions return e<sup>x</sup> - 1.
<h6>footnotes</h6>
<p><small><a name="note208" href="#note208">208)</a> For small magnitude x, expm1(x) is expected to be more accurate than exp(x) - 1.
</small>
-<a name="7.12.6.4" href="#7.12.6.4"><h5>7.12.6.4 The frexp functions</h5></a>
+<h5><a name="7.12.6.4" href="#7.12.6.4">7.12.6.4 The frexp functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
If value is not a floating-point number, the results are unspecified. Otherwise, the
frexp functions return the value x, such that x has a magnitude in the interval [1/2, 1) or
- zero, and value equals x x 2*exp . If value is zero, both parts of the result are zero.
+ zero, and value equals x 2<sup>*exp</sup> . If value is zero, both parts of the result are zero.
-<a name="7.12.6.5" href="#7.12.6.5"><h5>7.12.6.5 The ilogb functions</h5></a>
+<h5><a name="7.12.6.5" href="#7.12.6.5">7.12.6.5 The ilogb functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The ilogb functions return the exponent of x as a signed int value.
<p><b> Forward references</b>: the logb functions (<a href="#7.12.6.11">7.12.6.11</a>).
-<a name="7.12.6.6" href="#7.12.6.6"><h5>7.12.6.6 The ldexp functions</h5></a>
+<h5><a name="7.12.6.6" href="#7.12.6.6">7.12.6.6 The ldexp functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
range error may occur.
<h6>Returns</h6>
<p><!--para 3 -->
- The ldexp functions return x x 2exp .
+ The ldexp functions return x 2<sup>exp</sup> .
-<a name="7.12.6.7" href="#7.12.6.7"><h5>7.12.6.7 The log functions</h5></a>
+<h5><a name="7.12.6.7" href="#7.12.6.7">7.12.6.7 The log functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The log functions return loge x.
-<a name="7.12.6.8" href="#7.12.6.8"><h5>7.12.6.8 The log10 functions</h5></a>
+<h5><a name="7.12.6.8" href="#7.12.6.8">7.12.6.8 The log10 functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<!--page 238 -->
<p><!--para 3 -->
The log10 functions return log10 x.
-<a name="7.12.6.9" href="#7.12.6.9"><h5>7.12.6.9 The log1p functions</h5></a>
+<h5><a name="7.12.6.9" href="#7.12.6.9">7.12.6.9 The log1p functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note209" href="#note209">209)</a> For small magnitude x, log1p(x) is expected to be more accurate than log(1 + x).
</small>
-<a name="7.12.6.10" href="#7.12.6.10"><h5>7.12.6.10 The log2 functions</h5></a>
+<h5><a name="7.12.6.10" href="#7.12.6.10">7.12.6.10 The log2 functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 239 -->
-<a name="7.12.6.11" href="#7.12.6.11"><h5>7.12.6.11 The logb functions</h5></a>
+<h5><a name="7.12.6.11" href="#7.12.6.11">7.12.6.11 The logb functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
format. If x is subnormal it is treated as though it were normalized; thus, for positive
finite x,
<pre>
- 1 <= x x FLT_RADIX-logb(x) < FLT_RADIX</pre>
+ 1 <= x FLT_RADIX<sup>-logb(x)</sup> < FLT_RADIX</pre>
A domain error or range error may occur if the argument is zero.
<h6>Returns</h6>
<p><!--para 3 -->
The logb functions return the signed exponent of x.
-<a name="7.12.6.12" href="#7.12.6.12"><h5>7.12.6.12 The modf functions</h5></a>
+<h5><a name="7.12.6.12" href="#7.12.6.12">7.12.6.12 The modf functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The modf functions return the signed fractional part of value.
<!--page 240 -->
-<a name="7.12.6.13" href="#7.12.6.13"><h5>7.12.6.13 The scalbn and scalbln functions</h5></a>
+<h5><a name="7.12.6.13" href="#7.12.6.13">7.12.6.13 The scalbn and scalbln functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
long double scalblnl(long double x, long int n);</pre>
<h6>Description</h6>
<p><!--para 2 -->
- The scalbn and scalbln functions compute x x FLT_RADIXn efficiently, not
- normally by computing FLT_RADIXn explicitly. A range error may occur.
+ The scalbn and scalbln functions compute x FLT_RADIX<sup>n</sup> efficiently, not
+ normally by computing FLT_RADIX<sup>n</sup> explicitly. A range error may occur.
<h6>Returns</h6>
<p><!--para 3 -->
- The scalbn and scalbln functions return x x FLT_RADIXn .
+ The scalbn and scalbln functions return x FLT_RADIX<sup>n</sup> .
-<a name="7.12.7" href="#7.12.7"><h4>7.12.7 Power and absolute-value functions</h4></a>
+<h4><a name="7.12.7" href="#7.12.7">7.12.7 Power and absolute-value functions</a></h4>
-<a name="7.12.7.1" href="#7.12.7.1"><h5>7.12.7.1 The cbrt functions</h5></a>
+<h5><a name="7.12.7.1" href="#7.12.7.1">7.12.7.1 The cbrt functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The cbrt functions compute the real cube root of x.
<h6>Returns</h6>
<p><!--para 3 -->
- The cbrt functions return x1/3 .
+ The cbrt functions return x<sup>1/3</sup>.
-<a name="7.12.7.2" href="#7.12.7.2"><h5>7.12.7.2 The fabs functions</h5></a>
+<h5><a name="7.12.7.2" href="#7.12.7.2">7.12.7.2 The fabs functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The fabs functions return | x |.
-<a name="7.12.7.3" href="#7.12.7.3"><h5>7.12.7.3 The hypot functions</h5></a>
+<h5><a name="7.12.7.3" href="#7.12.7.3">7.12.7.3 The hypot functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
<h6>Returns</h6>
<p><!--para 4 -->
- The hypot functions return (sqrt)x2 + y2 .
-<pre>
- ???
- ???????????????</pre>
+ The hypot functions return (sqrt)(x<sup>2</sup> + y<sup>2</sup>).
-<a name="7.12.7.4" href="#7.12.7.4"><h5>7.12.7.4 The pow functions</h5></a>
+<h5><a name="7.12.7.4" href="#7.12.7.4">7.12.7.4 The pow functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
is zero and y is less than zero.
<h6>Returns</h6>
<p><!--para 3 -->
- The pow functions return xy .
+ The pow functions return x<sup>y</sup>.
-<a name="7.12.7.5" href="#7.12.7.5"><h5>7.12.7.5 The sqrt functions</h5></a>
+<h5><a name="7.12.7.5" href="#7.12.7.5">7.12.7.5 The sqrt functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<!--page 242 -->
the argument is less than zero.
<h6>Returns</h6>
<p><!--para 3 -->
- The sqrt functions return (sqrt)x.
-<pre>
- ???
- ???</pre>
+ The sqrt functions return (sqrt)(x).
-<a name="7.12.8" href="#7.12.8"><h4>7.12.8 Error and gamma functions</h4></a>
+<h4><a name="7.12.8" href="#7.12.8">7.12.8 Error and gamma functions</a></h4>
-<a name="7.12.8.1" href="#7.12.8.1"><h5>7.12.8.1 The erf functions</h5></a>
+<h5><a name="7.12.8.1" href="#7.12.8.1">7.12.8.1 The erf functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The erf functions compute the error function of x.
<h6>Returns</h6>
+<p><!--para 3 -->
+ The erf functions return
<pre>
- 2 x
- (integral)</pre>
-
- The erf functions return erf x = e-t dt.
-<pre>
- 2</pre>
-
-
-<pre>
- (sqrt)pi
- ???
- ??? 0</pre>
-
+ 2 x
+ erf x = --- (integral) e<sup>-t<sup>2</sup></sup> dt .
+ (sqrt)(pi) 0 </pre>
-<a name="7.12.8.2" href="#7.12.8.2"><h5>7.12.8.2 The erfc functions</h5></a>
+<h5><a name="7.12.8.2" href="#7.12.8.2">7.12.8.2 The erfc functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The erfc functions compute the complementary error function of x. A range error
occurs if x is too large.
<h6>Returns</h6>
+<p><!--para 3 -->
+ The erfc functions return
<pre>
- 2 (inf)
- (integral)</pre>
-
- The erfc functions return erfc x = 1 - erf x = e-t dt.
-<pre>
- 2</pre>
-
+ 2 (inf)
+ erfc x = 1 - erf x = --- (integral) e<sup>-t<sup>2</sup></sup> dt .
+ (sqrt)(pi) x </pre>
<!--page 243 -->
-<pre>
- (sqrt)pi
- ???
- ??? x</pre>
-
-<a name="7.12.8.3" href="#7.12.8.3"><h5>7.12.8.3 The lgamma functions</h5></a>
+<h5><a name="7.12.8.3" href="#7.12.8.3">7.12.8.3 The lgamma functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The lgamma functions return loge | (Gamma)(x) |.
-<a name="7.12.8.4" href="#7.12.8.4"><h5>7.12.8.4 The tgamma functions</h5></a>
+<h5><a name="7.12.8.4" href="#7.12.8.4">7.12.8.4 The tgamma functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The tgamma functions return (Gamma)(x).
-<a name="7.12.9" href="#7.12.9"><h4>7.12.9 Nearest integer functions</h4></a>
+<h4><a name="7.12.9" href="#7.12.9">7.12.9 Nearest integer functions</a></h4>
-<a name="7.12.9.1" href="#7.12.9.1"><h5>7.12.9.1 The ceil functions</h5></a>
+<h5><a name="7.12.9.1" href="#7.12.9.1">7.12.9.1 The ceil functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 244 -->
<h6>Returns</h6>
<p><!--para 3 -->
- The ceil functions return ???x???, expressed as a floating-point number.
+ The ceil functions return [^x^], expressed as a floating-point number.
-<a name="7.12.9.2" href="#7.12.9.2"><h5>7.12.9.2 The floor functions</h5></a>
+<h5><a name="7.12.9.2" href="#7.12.9.2">7.12.9.2 The floor functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The floor functions compute the largest integer value not greater than x.
<h6>Returns</h6>
<p><!--para 3 -->
- The floor functions return ???x???, expressed as a floating-point number.
+ The floor functions return [_x_], expressed as a floating-point number.
-<a name="7.12.9.3" href="#7.12.9.3"><h5>7.12.9.3 The nearbyint functions</h5></a>
+<h5><a name="7.12.9.3" href="#7.12.9.3">7.12.9.3 The nearbyint functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The nearbyint functions return the rounded integer value.
-<a name="7.12.9.4" href="#7.12.9.4"><h5>7.12.9.4 The rint functions</h5></a>
+<h5><a name="7.12.9.4" href="#7.12.9.4">7.12.9.4 The rint functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The rint functions return the rounded integer value.
-<a name="7.12.9.5" href="#7.12.9.5"><h5>7.12.9.5 The lrint and llrint functions</h5></a>
+<h5><a name="7.12.9.5" href="#7.12.9.5">7.12.9.5 The lrint and llrint functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The lrint and llrint functions return the rounded integer value.
-<a name="7.12.9.6" href="#7.12.9.6"><h5>7.12.9.6 The round functions</h5></a>
+<h5><a name="7.12.9.6" href="#7.12.9.6">7.12.9.6 The round functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The round functions return the rounded integer value.
<!--page 246 -->
-<a name="7.12.9.7" href="#7.12.9.7"><h5>7.12.9.7 The lround and llround functions</h5></a>
+<h5><a name="7.12.9.7" href="#7.12.9.7">7.12.9.7 The lround and llround functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The lround and llround functions return the rounded integer value.
-<a name="7.12.9.8" href="#7.12.9.8"><h5>7.12.9.8 The trunc functions</h5></a>
+<h5><a name="7.12.9.8" href="#7.12.9.8">7.12.9.8 The trunc functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The trunc functions return the truncated integer value.
<!--page 247 -->
-<a name="7.12.10" href="#7.12.10"><h4>7.12.10 Remainder functions</h4></a>
+<h4><a name="7.12.10" href="#7.12.10">7.12.10 Remainder functions</a></h4>
-<a name="7.12.10.1" href="#7.12.10.1"><h5>7.12.10.1 The fmod functions</h5></a>
+<h5><a name="7.12.10.1" href="#7.12.10.1">7.12.10.1 The fmod functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
whether a domain error occurs or the fmod functions return zero is implementation-
defined.
-<a name="7.12.10.2" href="#7.12.10.2"><h5>7.12.10.2 The remainder functions</h5></a>
+<h5><a name="7.12.10.2" href="#7.12.10.2">7.12.10.2 The remainder functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
x.'' This definition is applicable for all implementations.
</small>
-<a name="7.12.10.3" href="#7.12.10.3"><h5>7.12.10.3 The remquo functions</h5></a>
+<h5><a name="7.12.10.3" href="#7.12.10.3">7.12.10.3 The remquo functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The remquo functions compute the same remainder as the remainder functions. In
the object pointed to by quo they store a value whose sign is the sign of x/y and whose
- magnitude is congruent modulo 2n to the magnitude of the integral quotient of x/y, where
+ magnitude is congruent modulo 2<sup>n</sup> to the magnitude of the integral quotient of x/y, where
n is an implementation-defined integer greater than or equal to 3.
<h6>Returns</h6>
<p><!--para 3 -->
pointed to by quo is unspecified and whether a domain error occurs or the functions
return zero is implementation defined.
-<a name="7.12.11" href="#7.12.11"><h4>7.12.11 Manipulation functions</h4></a>
+<h4><a name="7.12.11" href="#7.12.11">7.12.11 Manipulation functions</a></h4>
-<a name="7.12.11.1" href="#7.12.11.1"><h5>7.12.11.1 The copysign functions</h5></a>
+<h5><a name="7.12.11.1" href="#7.12.11.1">7.12.11.1 The copysign functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The copysign functions return a value with the magnitude of x and the sign of y.
<!--page 249 -->
-<a name="7.12.11.2" href="#7.12.11.2"><h5>7.12.11.2 The nan functions</h5></a>
+<h5><a name="7.12.11.2" href="#7.12.11.2">7.12.11.2 The nan functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
If the implementation does not support quiet NaNs, the functions return zero.
<p><b> Forward references</b>: the strtod, strtof, and strtold functions (<a href="#7.20.1.3">7.20.1.3</a>).
-<a name="7.12.11.3" href="#7.12.11.3"><h5>7.12.11.3 The nextafter functions</h5></a>
+<h5><a name="7.12.11.3" href="#7.12.11.3">7.12.11.3 The nextafter functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
function.
</small>
-<a name="7.12.11.4" href="#7.12.11.4"><h5>7.12.11.4 The nexttoward functions</h5></a>
+<h5><a name="7.12.11.4" href="#7.12.11.4">7.12.11.4 The nexttoward functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
range or precision in a floating second argument.
</small>
-<a name="7.12.12" href="#7.12.12"><h4>7.12.12 Maximum, minimum, and positive difference functions</h4></a>
+<h4><a name="7.12.12" href="#7.12.12">7.12.12 Maximum, minimum, and positive difference functions</a></h4>
-<a name="7.12.12.1" href="#7.12.12.1"><h5>7.12.12.1 The fdim functions</h5></a>
+<h5><a name="7.12.12.1" href="#7.12.12.1">7.12.12.1 The fdim functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The fdim functions determine the positive difference between their arguments:
<pre>
- ???x - y if x > y
- ???
- ???+0 if x <= y</pre>
+ {x - y if x > y
+ {
+ {+0 if x <= y</pre>
A range error may occur.
<h6>Returns</h6>
<p><!--para 3 -->
The fdim functions return the positive difference value.
-<a name="7.12.12.2" href="#7.12.12.2"><h5>7.12.12.2 The fmax functions</h5></a>
+<h5><a name="7.12.12.2" href="#7.12.12.2">7.12.12.2 The fmax functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
fmax functions choose the numeric value. See <a href="#F.9.9.2">F.9.9.2</a>.
</small>
-<a name="7.12.12.3" href="#7.12.12.3"><h5>7.12.12.3 The fmin functions</h5></a>
+<h5><a name="7.12.12.3" href="#7.12.12.3">7.12.12.3 The fmin functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note214" href="#note214">214)</a> The fmin functions are analogous to the fmax functions in their treatment of NaNs.
</small>
-<a name="7.12.13" href="#7.12.13"><h4>7.12.13 Floating multiply-add</h4></a>
+<h4><a name="7.12.13" href="#7.12.13">7.12.13 Floating multiply-add</a></h4>
-<a name="7.12.13.1" href="#7.12.13.1"><h5>7.12.13.1 The fma functions</h5></a>
+<h5><a name="7.12.13.1" href="#7.12.13.1">7.12.13.1 The fma functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
long double z);</pre>
<h6>Description</h6>
<p><!--para 2 -->
- The fma functions compute (x x y) + z, rounded as one ternary operation: they compute
+ The fma functions compute (x y) + z, rounded as one ternary operation: they compute
the value (as if) to infinite precision and round once to the result format, according to the
current rounding mode. A range error may occur.
<h6>Returns</h6>
<p><!--para 3 -->
- The fma functions return (x x y) + z, rounded as one ternary operation.
+ The fma functions return (x y) + z, rounded as one ternary operation.
<!--page 252 -->
-<a name="7.12.14" href="#7.12.14"><h4>7.12.14 Comparison macros</h4></a>
+<h4><a name="7.12.14" href="#7.12.14">7.12.14 Comparison macros</a></h4>
<p><!--para 1 -->
The relational and equality operators support the usual mathematical relationships
between numeric values. For any ordered pair of numeric values exactly one of the
NaNs; the result in these cases is false.
</small>
-<a name="7.12.14.1" href="#7.12.14.1"><h5>7.12.14.1 The isgreater macro</h5></a>
+<h5><a name="7.12.14.1" href="#7.12.14.1">7.12.14.1 The isgreater macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The isgreater macro returns the value of (x) > (y).
-<a name="7.12.14.2" href="#7.12.14.2"><h5>7.12.14.2 The isgreaterequal macro</h5></a>
+<h5><a name="7.12.14.2" href="#7.12.14.2">7.12.14.2 The isgreaterequal macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The isgreaterequal macro returns the value of (x) >= (y).
-<a name="7.12.14.3" href="#7.12.14.3"><h5>7.12.14.3 The isless macro</h5></a>
+<h5><a name="7.12.14.3" href="#7.12.14.3">7.12.14.3 The isless macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The isless macro returns the value of (x) < (y).
-<a name="7.12.14.4" href="#7.12.14.4"><h5>7.12.14.4 The islessequal macro</h5></a>
+<h5><a name="7.12.14.4" href="#7.12.14.4">7.12.14.4 The islessequal macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The islessequal macro returns the value of (x) <= (y).
-<a name="7.12.14.5" href="#7.12.14.5"><h5>7.12.14.5 The islessgreater macro</h5></a>
+<h5><a name="7.12.14.5" href="#7.12.14.5">7.12.14.5 The islessgreater macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The islessgreater macro returns the value of (x) < (y) || (x) > (y).
-<a name="7.12.14.6" href="#7.12.14.6"><h5>7.12.14.6 The isunordered macro</h5></a>
+<h5><a name="7.12.14.6" href="#7.12.14.6">7.12.14.6 The isunordered macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The isunordered macro returns 1 if its arguments are unordered and 0 otherwise.
<!--page 255 -->
-<a name="7.13" href="#7.13"><h3>7.13 Nonlocal jumps <setjmp.h></h3></a>
+<h3><a name="7.13" href="#7.13">7.13 Nonlocal jumps <setjmp.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.13"><setjmp.h></a> defines the macro setjmp, and declares one function and
one type, for bypassing the normal function call and return discipline.<sup><a href="#note216"><b>216)</b></a></sup>
a program.
</small>
-<a name="7.13.1" href="#7.13.1"><h4>7.13.1 Save calling environment</h4></a>
+<h4><a name="7.13.1" href="#7.13.1">7.13.1 Save calling environment</a></h4>
-<a name="7.13.1.1" href="#7.13.1.1"><h5>7.13.1.1 The setjmp macro</h5></a>
+<h5><a name="7.13.1.1" href="#7.13.1.1">7.13.1.1 The setjmp macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
If the return is from a direct invocation, the setjmp macro returns the value zero. If the
return is from a call to the longjmp function, the setjmp macro returns a nonzero
value.
- Environmental limits
+<h6> Environmental limits</h6>
<p><!--para 4 -->
An invocation of the setjmp macro shall appear only in one of the following contexts:
<ul>
<p><!--para 5 -->
If the invocation appears in any other context, the behavior is undefined.
-<a name="7.13.2" href="#7.13.2"><h4>7.13.2 Restore calling environment</h4></a>
+<h4><a name="7.13.2" href="#7.13.2">7.13.2 Restore calling environment</a></h4>
-<a name="7.13.2.1" href="#7.13.2.1"><h5>7.13.2.1 The longjmp function</h5></a>
+<h5><a name="7.13.2.1" href="#7.13.2.1">7.13.2.1 The longjmp function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note218" href="#note218">218)</a> This includes, but is not limited to, the floating-point status flags and the state of open files.
</small>
-<a name="7.14" href="#7.14"><h3>7.14 Signal handling <signal.h></h3></a>
+<h3><a name="7.14" href="#7.14">7.14 Signal handling <signal.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.14"><signal.h></a> declares a type and two functions and defines several macros,
for handling various signals (conditions that may be reported during program execution).
and termination.
</small>
-<a name="7.14.1" href="#7.14.1"><h4>7.14.1 Specify signal handling</h4></a>
+<h4><a name="7.14.1" href="#7.14.1">7.14.1 Specify signal handling</a></h4>
-<a name="7.14.1.1" href="#7.14.1.1"><h5>7.14.1.1 The signal function</h5></a>
+<h5><a name="7.14.1.1" href="#7.14.1.1">7.14.1.1 The signal function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note220" href="#note220">220)</a> If any signal is generated by an asynchronous signal handler, the behavior is undefined.
</small>
-<a name="7.14.2" href="#7.14.2"><h4>7.14.2 Send signal</h4></a>
+<h4><a name="7.14.2" href="#7.14.2">7.14.2 Send signal</a></h4>
-<a name="7.14.2.1" href="#7.14.2.1"><h5>7.14.2.1 The raise function</h5></a>
+<h5><a name="7.14.2.1" href="#7.14.2.1">7.14.2.1 The raise function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The raise function returns zero if successful, nonzero if unsuccessful.
<!--page 261 -->
-<a name="7.15" href="#7.15"><h3>7.15 Variable arguments <stdarg.h></h3></a>
+<h3><a name="7.15" href="#7.15">7.15 Variable arguments <stdarg.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.15"><stdarg.h></a> declares a type and defines four macros, for advancing
through a list of arguments whose number and types are not known to the called function
case the original function may make further use of the original list after the other function returns.
</small>
-<a name="7.15.1" href="#7.15.1"><h4>7.15.1 Variable argument list access macros</h4></a>
+<h4><a name="7.15.1" href="#7.15.1">7.15.1 Variable argument list access macros</a></h4>
<p><!--para 1 -->
The va_start and va_arg macros described in this subclause shall be implemented
as macros, not functions. It is unspecified whether va_copy and va_end are macros or
shall be matched by a corresponding invocation of the va_end macro in the same
function.
-<a name="7.15.1.1" href="#7.15.1.1"><h5>7.15.1.1 The va_arg macro</h5></a>
+<h5><a name="7.15.1.1" href="#7.15.1.1">7.15.1.1 The va_arg macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
value of the argument after that specified by parmN . Successive invocations return the
values of the remaining arguments in succession.
-<a name="7.15.1.2" href="#7.15.1.2"><h5>7.15.1.2 The va_copy macro</h5></a>
+<h5><a name="7.15.1.2" href="#7.15.1.2">7.15.1.2 The va_copy macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The va_copy macro returns no value.
-<a name="7.15.1.3" href="#7.15.1.3"><h5>7.15.1.3 The va_end macro</h5></a>
+<h5><a name="7.15.1.3" href="#7.15.1.3">7.15.1.3 The va_end macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The va_end macro returns no value.
-<a name="7.15.1.4" href="#7.15.1.4"><h5>7.15.1.4 The va_start macro</h5></a>
+<h5><a name="7.15.1.4" href="#7.15.1.4">7.15.1.4 The va_start macro</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
va_list ap;
char *array[MAXARGS];
int ptr_no = 0;
- if (n_ptrs > MAXARGS)
- n_ptrs = MAXARGS;
- va_start(ap, n_ptrs);
- while (ptr_no < n_ptrs)
- array[ptr_no++] = va_arg(ap, char *);
- va_end(ap);
- f2(n_ptrs, array);
+ if (n_ptrs > MAXARGS)
+ n_ptrs = MAXARGS;
+ va_start(ap, n_ptrs);
+ while (ptr_no < n_ptrs)
+ array[ptr_no++] = va_arg(ap, char *);
+ va_end(ap);
+ f2(n_ptrs, array);
}</pre>
Each call to f1 is required to have visible the definition of the function or a declaration such as
<pre>
f4(n_ptrs, array);
}</pre>
-<a name="7.16" href="#7.16"><h3>7.16 Boolean type and values <stdbool.h></h3></a>
+<h3><a name="7.16" href="#7.16">7.16 Boolean type and values <stdbool.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.16"><stdbool.h></a> defines four macros.
<p><!--para 2 -->
<p><small><a name="note222" href="#note222">222)</a> See ''future library directions'' (<a href="#7.26.7">7.26.7</a>).
</small>
-<a name="7.17" href="#7.17"><h3>7.17 Common definitions <stddef.h></h3></a>
+<h3><a name="7.17" href="#7.17">7.17 Common definitions <stddef.h></a></h3>
<p><!--para 1 -->
The following types and macros are defined in the standard header <a href="#7.17"><stddef.h></a>. Some
are also defined in other headers, as noted in their respective subclauses.
static type t;</pre>
then the expression &(t.member-designator) evaluates to an address constant. (If the
specified member is a bit-field, the behavior is undefined.)
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 4 -->
The types used for size_t and ptrdiff_t should not have an integer conversion rank
greater than that of signed long int unless the implementation supports objects
<p><b> Forward references</b>: localization (<a href="#7.11">7.11</a>).
<!--page 267 -->
-<a name="7.18" href="#7.18"><h3>7.18 Integer types <stdint.h></h3></a>
+<h3><a name="7.18" href="#7.18">7.18 Integer types <stdint.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.18"><stdint.h></a> declares sets of integer types having specified widths, and
defines corresponding sets of macros.<sup><a href="#note223"><b>223)</b></a></sup> It also defines macros that specify limits of
<p><small><a name="note224" href="#note224">224)</a> Some of these types may denote implementation-defined extended integer types.
</small>
-<a name="7.18.1" href="#7.18.1"><h4>7.18.1 Integer types</h4></a>
+<h4><a name="7.18.1" href="#7.18.1">7.18.1 Integer types</a></h4>
<p><!--para 1 -->
When typedef names differing only in the absence or presence of the initial u are defined,
they shall denote corresponding signed and unsigned types as described in <a href="#6.2.5">6.2.5</a>; an
<!--page 268 -->
-<a name="7.18.1.1" href="#7.18.1.1"><h5>7.18.1.1 Exact-width integer types</h5></a>
+<h5><a name="7.18.1.1" href="#7.18.1.1">7.18.1.1 Exact-width integer types</a></h5>
<p><!--para 1 -->
The typedef name intN_t designates a signed integer type with width N , no padding
bits, and a two's complement representation. Thus, int8_t denotes a signed integer
widths of 8, 16, 32, or 64 bits, no padding bits, and (for the signed types) that have a
two's complement representation, it shall define the corresponding typedef names.
-<a name="7.18.1.2" href="#7.18.1.2"><h5>7.18.1.2 Minimum-width integer types</h5></a>
+<h5><a name="7.18.1.2" href="#7.18.1.2">7.18.1.2 Minimum-width integer types</a></h5>
<p><!--para 1 -->
The typedef name int_leastN_t designates a signed integer type with a width of at
least N , such that no signed integer type with lesser size has at least the specified width.
int_least64_t uint_least64_t</pre>
All other types of this form are optional.
-<a name="7.18.1.3" href="#7.18.1.3"><h5>7.18.1.3 Fastest minimum-width integer types</h5></a>
+<h5><a name="7.18.1.3" href="#7.18.1.3">7.18.1.3 Fastest minimum-width integer types</a></h5>
<p><!--para 1 -->
Each of the following types designates an integer type that is usually fastest<sup><a href="#note225"><b>225)</b></a></sup> to operate
with among all integer types that have at least the specified width.
signedness and width requirements.
</small>
-<a name="7.18.1.4" href="#7.18.1.4"><h5>7.18.1.4 Integer types capable of holding object pointers</h5></a>
+<h5><a name="7.18.1.4" href="#7.18.1.4">7.18.1.4 Integer types capable of holding object pointers</a></h5>
<p><!--para 1 -->
The following type designates a signed integer type with the property that any valid
pointer to void can be converted to this type, then converted back to pointer to void,
uintptr_t</pre>
These types are optional.
-<a name="7.18.1.5" href="#7.18.1.5"><h5>7.18.1.5 Greatest-width integer types</h5></a>
+<h5><a name="7.18.1.5" href="#7.18.1.5">7.18.1.5 Greatest-width integer types</a></h5>
<p><!--para 1 -->
The following type designates a signed integer type capable of representing any value of
any signed integer type:
uintmax_t</pre>
These types are required.
-<a name="7.18.2" href="#7.18.2"><h4>7.18.2 Limits of specified-width integer types</h4></a>
+<h4><a name="7.18.2" href="#7.18.2">7.18.2 Limits of specified-width integer types</a></h4>
<p><!--para 1 -->
The following object-like macros<sup><a href="#note226"><b>226)</b></a></sup> specify the minimum and maximum limits of the
types declared in <a href="#7.18"><stdint.h></a>. Each macro name corresponds to a similar type name in
before <a href="#7.18"><stdint.h></a> is included.
</small>
-<a name="7.18.2.1" href="#7.18.2.1"><h5>7.18.2.1 Limits of exact-width integer types</h5></a>
+<h5><a name="7.18.2.1" href="#7.18.2.1">7.18.2.1 Limits of exact-width integer types</a></h5>
<p><!--para 1 -->
<ul>
<li> minimum values of exact-width signed integer types
- INTN_MIN exactly -(2 N -1 )
+<pre>
+ INTN_MIN exactly -(2<sup>N-1</sup>)</pre>
<li> maximum values of exact-width signed integer types
- INTN_MAX exactly 2 N -1 - 1
+<pre>
+ INTN_MAX exactly 2<sup>N-1</sup> - 1</pre>
<li> maximum values of exact-width unsigned integer types
- UINTN_MAX exactly 2 N - 1
+<pre>
+ UINTN_MAX exactly 2<sup>N</sup> - 1</pre>
</ul>
-<a name="7.18.2.2" href="#7.18.2.2"><h5>7.18.2.2 Limits of minimum-width integer types</h5></a>
+<h5><a name="7.18.2.2" href="#7.18.2.2">7.18.2.2 Limits of minimum-width integer types</a></h5>
<p><!--para 1 -->
<ul>
<li> minimum values of minimum-width signed integer types
- INT_LEASTN_MIN -(2 N -1 - 1)
+<pre>
+ INT_LEASTN_MIN -(2<sup>N-1</sup> - 1)</pre>
<li> maximum values of minimum-width signed integer types
- INT_LEASTN_MAX 2 N -1 - 1
+<pre>
+ INT_LEASTN_MAX 2<sup>N-1</sup> - 1</pre>
<li> maximum values of minimum-width unsigned integer types
- UINT_LEASTN_MAX 2N - 1
+<pre>
+ UINT_LEASTN_MAX 2<sup>N</sup> - 1</pre>
</ul>
-<a name="7.18.2.3" href="#7.18.2.3"><h5>7.18.2.3 Limits of fastest minimum-width integer types</h5></a>
+<h5><a name="7.18.2.3" href="#7.18.2.3">7.18.2.3 Limits of fastest minimum-width integer types</a></h5>
<p><!--para 1 -->
<ul>
<li> minimum values of fastest minimum-width signed integer types
- INT_FASTN_MIN -(2 N -1 - 1)
+<pre>
+ INT_FASTN_MIN -(2<sup>N-1</sup> - 1)</pre>
<li> maximum values of fastest minimum-width signed integer types
- INT_FASTN_MAX 2 N -1 - 1
+<pre>
+ INT_FASTN_MAX 2<sup>N-1</sup> - 1</pre>
<li> maximum values of fastest minimum-width unsigned integer types
- UINT_FASTN_MAX 2N - 1
+<pre>
+ UINT_FASTN_MAX 2<sup>N</sup> - 1</pre>
</ul>
-<a name="7.18.2.4" href="#7.18.2.4"><h5>7.18.2.4 Limits of integer types capable of holding object pointers</h5></a>
+<h5><a name="7.18.2.4" href="#7.18.2.4">7.18.2.4 Limits of integer types capable of holding object pointers</a></h5>
<p><!--para 1 -->
<ul>
<li> minimum value of pointer-holding signed integer type
<pre>
- INTPTR_MIN -(215 - 1)</pre>
+ INTPTR_MIN -(2<sup>15</sup> - 1)</pre>
<li> maximum value of pointer-holding signed integer type
<!--page 271 -->
<pre>
- INTPTR_MAX 215 - 1</pre>
+ INTPTR_MAX 2<sup>15</sup> - 1</pre>
<li> maximum value of pointer-holding unsigned integer type
- UINTPTR_MAX 216 - 1
+<pre>
+ UINTPTR_MAX 2<sup>16</sup> - 1</pre>
</ul>
-<a name="7.18.2.5" href="#7.18.2.5"><h5>7.18.2.5 Limits of greatest-width integer types</h5></a>
+<h5><a name="7.18.2.5" href="#7.18.2.5">7.18.2.5 Limits of greatest-width integer types</a></h5>
<p><!--para 1 -->
<ul>
<li> minimum value of greatest-width signed integer type
- INTMAX_MIN -(263 - 1)
+<pre>
+ INTMAX_MIN -(2<sup>63</sup> - 1)</pre>
<li> maximum value of greatest-width signed integer type
- INTMAX_MAX 263 - 1
+<pre>
+ INTMAX_MAX 2<sup>63</sup> - 1</pre>
<li> maximum value of greatest-width unsigned integer type
- UINTMAX_MAX 264 - 1
+<pre>
+ UINTMAX_MAX 2<sup>64</sup> - 1</pre>
</ul>
-<a name="7.18.3" href="#7.18.3"><h4>7.18.3 Limits of other integer types</h4></a>
+<h4><a name="7.18.3" href="#7.18.3">7.18.3 Limits of other integer types</a></h4>
<p><!--para 1 -->
The following object-like macros<sup><a href="#note227"><b>227)</b></a></sup> specify the minimum and maximum limits of
integer types corresponding to types defined in other standard headers.
actually provides.<sup><a href="#note228"><b>228)</b></a></sup>
<ul>
<li> limits of ptrdiff_t
- PTRDIFF_MIN -65535
- PTRDIFF_MAX +65535
+<pre>
+ PTRDIFF_MIN -65535
+ PTRDIFF_MAX +65535
+</pre>
<li> limits of sig_atomic_t
- SIG_ATOMIC_MIN see below
- SIG_ATOMIC_MAX see below
+<pre>
+ SIG_ATOMIC_MIN see below
+ SIG_ATOMIC_MAX see below
+</pre>
<li> limit of size_t
- SIZE_MAX 65535
+<pre>
+ SIZE_MAX 65535
+</pre>
<li> limits of wchar_t
-
-
<!--page 272 -->
- WCHAR_MIN see below
- WCHAR_MAX see below
+<pre>
+ WCHAR_MIN see below
+ WCHAR_MAX see below
+</pre>
<li> limits of wint_t
- WINT_MIN see below
- WINT_MAX see below
+<pre>
+ WINT_MIN see below
+ WINT_MAX see below
+</pre>
</ul>
<p><!--para 3 -->
If sig_atomic_t (see <a href="#7.14">7.14</a>) is defined as a signed integer type, the value of
character set.
</small>
-<a name="7.18.4" href="#7.18.4"><h4>7.18.4 Macros for integer constants</h4></a>
+<h4><a name="7.18.4" href="#7.18.4">7.18.4 Macros for integer constants</a></h4>
<p><!--para 1 -->
The following function-like macros<sup><a href="#note230"><b>230)</b></a></sup> expand to integer constants suitable for
initializing objects that have integer types corresponding to types defined in
defined before <a href="#7.18"><stdint.h></a> is included.
</small>
-<a name="7.18.4.1" href="#7.18.4.1"><h5>7.18.4.1 Macros for minimum-width integer constants</h5></a>
+<h5><a name="7.18.4.1" href="#7.18.4.1">7.18.4.1 Macros for minimum-width integer constants</a></h5>
<p><!--para 1 -->
The macro INTN_C(value) shall expand to an integer constant expression
corresponding to the type int_leastN_t. The macro UINTN_C(value) shall expand
example, if uint_least64_t is a name for the type unsigned long long int,
then UINT64_C(0x123) might expand to the integer constant 0x123ULL.
-<a name="7.18.4.2" href="#7.18.4.2"><h5>7.18.4.2 Macros for greatest-width integer constants</h5></a>
+<h5><a name="7.18.4.2" href="#7.18.4.2">7.18.4.2 Macros for greatest-width integer constants</a></h5>
<p><!--para 1 -->
The following macro expands to an integer constant expression having the value specified
by its argument and the type intmax_t:
<pre>
UINTMAX_C(value)</pre>
-<a name="7.19" href="#7.19"><h3>7.19 Input/output <stdio.h></h3></a>
+<h3><a name="7.19" href="#7.19">7.19 Input/output <stdio.h></a></h3>
-<a name="7.19.1" href="#7.19.1"><h4>7.19.1 Introduction</h4></a>
+<h4><a name="7.19.1" href="#7.19.1">7.19.1 Introduction</a></h4>
<p><!--para 1 -->
The header <a href="#7.19"><stdio.h></a> declares three types, several macros, and many functions for
performing input and output.
all possible strings of length FILENAME_MAX cannot be expected to be opened successfully.
</small>
-<a name="7.19.2" href="#7.19.2"><h4>7.19.2 Streams</h4></a>
+<h4><a name="7.19.2" href="#7.19.2">7.19.2 Streams</a></h4>
<p><!--para 1 -->
Input and output, whether to or from physical devices such as terminals and tape drives,
or whether to or from files supported on structured storage devices, are mapped into
value of this mbstate_t object as part of the value of the fpos_t object. A later
successful call to fsetpos using the same stored fpos_t value restores the value of
the associated mbstate_t object as well as the position within the controlled stream.
- Environmental limits
+<h6> Environmental limits</h6>
<p><!--para 7 -->
An implementation shall support text files with lines containing at least 254 characters,
including the terminating new-line character. The value of the macro BUFSIZ shall be at
<p><small><a name="note233" href="#note233">233)</a> The three predefined streams stdin, stdout, and stderr are unoriented at program startup.
</small>
-<a name="7.19.3" href="#7.19.3"><h4>7.19.3 Files</h4></a>
+<h4><a name="7.19.3" href="#7.19.3">7.19.3 Files</a></h4>
<p><!--para 1 -->
A stream is associated with an external file (which may be a physical device) by opening
a file, which may involve creating a new file. Creating an existing file causes its former
<!--page 279 -->
<p><!--para 7 -->
At program startup, three text streams are predefined and need not be opened explicitly
-<ul>
-<li> standard input (for reading conventional input), standard output (for writing
-</ul>
+ -- standard input (for reading conventional input), standard output (for writing
conventional output), and standard error (for writing diagnostic output). As initially
opened, the standard error stream is not fully buffered; the standard input and standard
output streams are fully buffered if and only if the stream can be determined not to refer
multibyte character. The wide character input/output functions and the byte input/output
functions store the value of the macro EILSEQ in errno if and only if an encoding error
occurs.
- Environmental limits
+<h6> Environmental limits</h6>
<p><!--para 15 -->
The value of FOPEN_MAX shall be at least eight, including the three standard text
streams.
with state-dependent encoding that does not assuredly end in the initial shift state.
</small>
-<a name="7.19.4" href="#7.19.4"><h4>7.19.4 Operations on files</h4></a>
+<h4><a name="7.19.4" href="#7.19.4">7.19.4 Operations on files</a></h4>
-<a name="7.19.4.1" href="#7.19.4.1"><h5>7.19.4.1 The remove function</h5></a>
+<h5><a name="7.19.4.1" href="#7.19.4.1">7.19.4.1 The remove function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The remove function returns zero if the operation succeeds, nonzero if it fails.
-<a name="7.19.4.2" href="#7.19.4.2"><h5>7.19.4.2 The rename function</h5></a>
+<h5><a name="7.19.4.2" href="#7.19.4.2">7.19.4.2 The rename function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
or that it is necessary to copy its contents to effectuate its renaming.
</small>
-<a name="7.19.4.3" href="#7.19.4.3"><h5>7.19.4.3 The tmpfile function</h5></a>
+<h5><a name="7.19.4.3" href="#7.19.4.3">7.19.4.3 The tmpfile function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
existing file and that will automatically be removed when it is closed or at program
termination. If the program terminates abnormally, whether an open temporary file is
removed is implementation-defined. The file is opened for update with "wb+" mode.
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 3 -->
It should be possible to open at least TMP_MAX temporary files during the lifetime of the
program (this limit may be shared with tmpnam) and there should be no limit on the
cannot be created, the tmpfile function returns a null pointer.
<p><b> Forward references</b>: the fopen function (<a href="#7.19.5.3">7.19.5.3</a>).
-<a name="7.19.4.4" href="#7.19.4.4"><h5>7.19.4.4 The tmpnam function</h5></a>
+<h5><a name="7.19.4.4" href="#7.19.4.4">7.19.4.4 The tmpnam function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
function may modify the same object). If the argument is not a null pointer, it is assumed
to point to an array of at least L_tmpnam chars; the tmpnam function writes its result
in that array and returns the argument as its value.
- Environmental limits
+<h6> Environmental limits</h6>
<p><!--para 6 -->
The value of the macro TMP_MAX shall be at least 25.
is ended, and before program termination.
</small>
-<a name="7.19.5" href="#7.19.5"><h4>7.19.5 File access functions</h4></a>
+<h4><a name="7.19.5" href="#7.19.5">7.19.5 File access functions</a></h4>
-<a name="7.19.5.1" href="#7.19.5.1"><h5>7.19.5.1 The fclose function</h5></a>
+<h5><a name="7.19.5.1" href="#7.19.5.1">7.19.5.1 The fclose function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The fclose function returns zero if the stream was successfully closed, or EOF if any
errors were detected.
-<a name="7.19.5.2" href="#7.19.5.2"><h5>7.19.5.2 The fflush function</h5></a>
+<h5><a name="7.19.5.2" href="#7.19.5.2">7.19.5.2 The fflush function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<!--page 283 -->
error occurs, otherwise it returns zero.
<p><b> Forward references</b>: the fopen function (<a href="#7.19.5.3">7.19.5.3</a>).
-<a name="7.19.5.3" href="#7.19.5.3"><h5>7.19.5.3 The fopen function</h5></a>
+<h5><a name="7.19.5.3" href="#7.19.5.3">7.19.5.3 The fopen function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The argument mode points to a string. If the string is one of the following, the file is
open in the indicated mode. Otherwise, the behavior is undefined.<sup><a href="#note237"><b>237)</b></a></sup>
- r open text file for reading
- w truncate to zero length or create text file for writing
- a append; open or create text file for writing at end-of-file
- rb open binary file for reading
- wb truncate to zero length or create binary file for writing
- ab append; open or create binary file for writing at end-of-file
- r+ open text file for update (reading and writing)
- w+ truncate to zero length or create text file for update
- a+ append; open or create text file for update, writing at end-of-file
-
-
-
+<dl>
+<dt> r <dd>open text file for reading
+<dt> w <dd>truncate to zero length or create text file for writing
+<dt> a <dd>append; open or create text file for writing at end-of-file
+<dt> rb <dd>open binary file for reading
+<dt> wb <dd>truncate to zero length or create binary file for writing
+<dt> ab <dd><dd>append; open or create binary file for writing at end-of-file
+<dt> r+ <dd>open text file for update (reading and writing)
+<dt> w+ <dd>truncate to zero length or create text file for update
+<dt> a+ <dd>append; open or create text file for update, writing at end-of-file
<!--page 284 -->
- r+b or rb+ open binary file for update (reading and writing)
- w+b or wb+ truncate to zero length or create binary file for update
- a+b or ab+ append; open or create binary file for update, writing at end-of-file
+<dt> r+b or rb+ <dd>open binary file for update (reading and writing)
+<dt> w+b or wb+ <dd>truncate to zero length or create binary file for update
+<dt> a+b or ab+ <dd>append; open or create binary file for update, writing at end-of-file
+</dl>
<p><!--para 4 -->
Opening a file with read mode ('r' as the first character in the mode argument) fails if
the file does not exist or cannot be read.
conform to the properties in <a href="#7.19.2">7.19.2</a>).
</small>
-<a name="7.19.5.4" href="#7.19.5.4"><h5>7.19.5.4 The freopen function</h5></a>
+<h5><a name="7.19.5.4" href="#7.19.5.4">7.19.5.4 The freopen function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
returned by the fopen function may be assigned.
</small>
-<a name="7.19.5.5" href="#7.19.5.5"><h5>7.19.5.5 The setbuf function</h5></a>
+<h5><a name="7.19.5.5" href="#7.19.5.5">7.19.5.5 The setbuf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The setbuf function returns no value.
<p><b> Forward references</b>: the setvbuf function (<a href="#7.19.5.6">7.19.5.6</a>).
-<a name="7.19.5.6" href="#7.19.5.6"><h5>7.19.5.6 The setvbuf function</h5></a>
+<h5><a name="7.19.5.6" href="#7.19.5.6">7.19.5.6 The setvbuf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
before a buffer that has automatic storage duration is deallocated upon block exit.
</small>
-<a name="7.19.6" href="#7.19.6"><h4>7.19.6 Formatted input/output functions</h4></a>
+<h4><a name="7.19.6" href="#7.19.6">7.19.6 Formatted input/output functions</a></h4>
<p><!--para 1 -->
The formatted input/output functions shall behave as if there is a sequence point after the
actions associated with each specifier.<sup><a href="#note240"><b>240)</b></a></sup>
<p><small><a name="note240" href="#note240">240)</a> The fprintf functions perform writes to memory for the %n specifier.
</small>
-<a name="7.19.6.1" href="#7.19.6.1"><h5>7.19.6.1 The fprintf function</h5></a>
+<h5><a name="7.19.6.1" href="#7.19.6.1">7.19.6.1 The fprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
precision were omitted.
<p><!--para 6 -->
The flag characters and their meanings are:
- - The result of the conversion is left-justified within the field. (It is right-justified if
-<pre>
- this flag is not specified.)</pre>
- + The result of a signed conversion always begins with a plus or minus sign. (It
-<pre>
- begins with a sign only when a negative value is converted if this flag is not</pre>
-
-
-
+<dl>
+<dt> - <dd> The result of the conversion is left-justified within the field. (It is right-justified if
+ this flag is not specified.)
+<dt> + <dd> The result of a signed conversion always begins with a plus or minus sign. (It
+ begins with a sign only when a negative value is converted if this flag is not
<!--page 288 -->
-<pre>
- specified.)<sup><a href="#note242"><b>242)</b></a></sup></pre>
- space If the first character of a signed conversion is not a sign, or if a signed conversion
-<pre>
+ specified.)<sup><a href="#note242"><b>242)</b></a></sup>
+<dt> space<dd> If the first character of a signed conversion is not a sign, or if a signed conversion
results in no characters, a space is prefixed to the result. If the space and + flags
- both appear, the space flag is ignored.</pre>
- # The result is converted to an ''alternative form''. For o conversion, it increases
-<pre>
+ both appear, the space flag is ignored.
+<dt> # <dd> The result is converted to an ''alternative form''. For o conversion, it increases
the precision, if and only if necessary, to force the first digit of the result to be a
zero (if the value and precision are both 0, a single 0 is printed). For x (or X)
conversion, a nonzero result has 0x (or 0X) prefixed to it. For a, A, e, E, f, F, g,
contains a decimal-point character, even if no digits follow it. (Normally, a
decimal-point character appears in the result of these conversions only if a digit
follows it.) For g and G conversions, trailing zeros are not removed from the
- result. For other conversions, the behavior is undefined.</pre>
- 0 For d, i, o, u, x, X, a, A, e, E, f, F, g, and G conversions, leading zeros
-<p><!--para 7 -->
-<pre>
+ result. For other conversions, the behavior is undefined.
+<dt> 0 <dd> For d, i, o, u, x, X, a, A, e, E, f, F, g, and G conversions, leading zeros
(following any indication of sign or base) are used to pad to the field width rather
than performing space padding, except when converting an infinity or NaN. If the
0 and - flags both appear, the 0 flag is ignored. For d, i, o, u, x, and X
conversions, if a precision is specified, the 0 flag is ignored. For other
- conversions, the behavior is undefined.</pre>
+ conversions, the behavior is undefined.
+</dl>
+<p><!--para 7 -->
The length modifiers and their meanings are:
- hh Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+<dl>
+<dt> hh <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
signed char or unsigned char argument (the argument will have
been promoted according to the integer promotions, but its value shall be
converted to signed char or unsigned char before printing); or that
a following n conversion specifier applies to a pointer to a signed char
- argument.</pre>
- h Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+ argument.
+<dt> h <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
short int or unsigned short int argument (the argument will
have been promoted according to the integer promotions, but its value shall
be converted to short int or unsigned short int before printing);
or that a following n conversion specifier applies to a pointer to a short
- int argument.</pre>
- l (ell) Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+ int argument.
+<dt> l (ell) <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
long int or unsigned long int argument; that a following n
- conversion specifier applies to a pointer to a long int argument; that a</pre>
-
+ conversion specifier applies to a pointer to a long int argument; that a
<!--page 289 -->
-<pre>
following c conversion specifier applies to a wint_t argument; that a
following s conversion specifier applies to a pointer to a wchar_t
argument; or has no effect on a following a, A, e, E, f, F, g, or G conversion
- specifier.</pre>
- ll (ell-ell) Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+ specifier.
+<dt> ll (ell-ell)<dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
long long int or unsigned long long int argument; or that a
following n conversion specifier applies to a pointer to a long long int
- argument.</pre>
- j Specifies that a following d, i, o, u, x, or X conversion specifier applies to
-<pre>
+ argument.
+<dt> j <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to
an intmax_t or uintmax_t argument; or that a following n conversion
- specifier applies to a pointer to an intmax_t argument.</pre>
- z Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+ specifier applies to a pointer to an intmax_t argument.
+<dt> z <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
size_t or the corresponding signed integer type argument; or that a
following n conversion specifier applies to a pointer to a signed integer type
- corresponding to size_t argument.</pre>
- t Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+ corresponding to size_t argument.
+<dt> t <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
ptrdiff_t or the corresponding unsigned integer type argument; or that a
following n conversion specifier applies to a pointer to a ptrdiff_t
- argument.</pre>
- L Specifies that a following a, A, e, E, f, F, g, or G conversion specifier
-<pre>
- applies to a long double argument.</pre>
- If a length modifier appears with any conversion specifier other than as specified above,
+ argument.
+<dt> L <dd> Specifies that a following a, A, e, E, f, F, g, or G conversion specifier
+ applies to a long double argument.
+</dl>
+If a length modifier appears with any conversion specifier other than as specified above,
the behavior is undefined.
<p><!--para 8 -->
The conversion specifiers and their meanings are:
- d,i The int argument is converted to signed decimal in the style [-]dddd. The
-<pre>
+<dl>
+<dt> d,i <dd> The int argument is converted to signed decimal in the style [-]dddd. The
precision specifies the minimum number of digits to appear; if the value
being converted can be represented in fewer digits, it is expanded with
leading zeros. The default precision is 1. The result of converting a zero
- value with a precision of zero is no characters.</pre>
- o,u,x,X The unsigned int argument is converted to unsigned octal (o), unsigned
+ value with a precision of zero is no characters.
+<dt> o,u,x,X<dd> The unsigned int argument is converted to unsigned octal (o), unsigned
<!--page 290 -->
-<pre>
decimal (u), or unsigned hexadecimal notation (x or X) in the style dddd; the
letters abcdef are used for x conversion and the letters ABCDEF for X
conversion. The precision specifies the minimum number of digits to appear;
if the value being converted can be represented in fewer digits, it is expanded
with leading zeros. The default precision is 1. The result of converting a
- zero value with a precision of zero is no characters.</pre>
- f,F A double argument representing a floating-point number is converted to
-<pre>
+ zero value with a precision of zero is no characters.
+<dt> f,F <dd> A double argument representing a floating-point number is converted to
decimal notation in the style [-]ddd.ddd, where the number of digits after
the decimal-point character is equal to the precision specification. If the
precision is missing, it is taken as 6; if the precision is zero and the # flag is
[-]nan or [-]nan(n-char-sequence) -- which style, and the meaning of
any n-char-sequence, is implementation-defined. The F conversion specifier
produces INF, INFINITY, or NAN instead of inf, infinity, or nan,
- respectively.<sup><a href="#note243"><b>243)</b></a></sup></pre>
- e,E A double argument representing a floating-point number is converted in the
-<pre>
+ respectively.<sup><a href="#note243"><b>243)</b></a></sup>
+<dt> e,E <dd> A double argument representing a floating-point number is converted in the
style [-]d.ddd e(+-)dd, where there is one digit (which is nonzero if the
argument is nonzero) before the decimal-point character and the number of
digits after it is equal to the precision; if the precision is missing, it is taken as
and only as many more digits as necessary to represent the exponent. If the
value is zero, the exponent is zero.
A double argument representing an infinity or NaN is converted in the style
- of an f or F conversion specifier.</pre>
- g,G A double argument representing a floating-point number is converted in
-<pre>
+ of an f or F conversion specifier.
+<dt> g,G <dd> A double argument representing a floating-point number is converted in
style f or e (or in style F or E in the case of a G conversion specifier),
depending on the value converted and the precision. Let P equal the
precision if nonzero, 6 if the precision is omitted, or 1 if the precision is zero.
Then, if a conversion with style E would have an exponent of X :
- -- if P > X >= -4, the conversion is with style f (or F) and precision
+ <ul>
+ <li> if P > X >= -4, the conversion is with style f (or F) and precision
P - (X + 1).
- -- otherwise, the conversion is with style e (or E) and precision P - 1.
- Finally, unless the # flag is used, any trailing zeros are removed from the</pre>
-
+ <li> otherwise, the conversion is with style e (or E) and precision P - 1.
+ </ul>
+ Finally, unless the # flag is used, any trailing zeros are removed from the
<!--page 291 -->
-<pre>
fractional portion of the result and the decimal-point character is removed if
there is no fractional portion remaining.
A double argument representing an infinity or NaN is converted in the style
- of an f or F conversion specifier.</pre>
- a,A A double argument representing a floating-point number is converted in the
-<pre>
+ of an f or F conversion specifier.
+<dt> a,A <dd> A double argument representing a floating-point number is converted in the
style [-]0xh.hhhh p(+-)d, where there is one hexadecimal digit (which is
nonzero if the argument is a normalized floating-point number and is
otherwise unspecified) before the decimal-point character<sup><a href="#note244"><b>244)</b></a></sup> and the number
least one digit, and only as many more digits as necessary to represent the
decimal exponent of 2. If the value is zero, the exponent is zero.
A double argument representing an infinity or NaN is converted in the style
- of an f or F conversion specifier.</pre>
- c If no l length modifier is present, the int argument is converted to an
-<pre>
+ of an f or F conversion specifier.
+<dt> c <dd> If no l length modifier is present, the int argument is converted to an
unsigned char, and the resulting character is written.
If an l length modifier is present, the wint_t argument is converted as if by
an ls conversion specification with no precision and an argument that points
to the initial element of a two-element array of wchar_t, the first element
containing the wint_t argument to the lc conversion specification and the
- second a null wide character.</pre>
- s If no l length modifier is present, the argument shall be a pointer to the initial
-<pre>
- element of an array of character type.<sup><a href="#note246"><b>246)</b></a></sup> Characters from the array are</pre>
-
-
+ second a null wide character.
+<dt> s <dd> If no l length modifier is present, the argument shall be a pointer to the initial
+ element of an array of character type.<sup><a href="#note246"><b>246)</b></a></sup> Characters from the array are
<!--page 292 -->
-<pre>
written up to (but not including) the terminating null character. If the
precision is specified, no more than that many bytes are written. If the
precision is not specified or is greater than the size of the array, the array shall
written (including shift sequences, if any), and the array shall contain a null
wide character if, to equal the multibyte character sequence length given by
the precision, the function would need to access a wide character one past the
- end of the array. In no case is a partial multibyte character written.<sup><a href="#note247"><b>247)</b></a></sup></pre>
- p The argument shall be a pointer to void. The value of the pointer is
-<pre>
+ end of the array. In no case is a partial multibyte character written.<sup><a href="#note247"><b>247)</b></a></sup>
+<dt> p <dd> The argument shall be a pointer to void. The value of the pointer is
converted to a sequence of printing characters, in an implementation-defined
- manner.</pre>
- n The argument shall be a pointer to signed integer into which is written the
-<pre>
+ manner.
+<dt> n <dd> The argument shall be a pointer to signed integer into which is written the
number of characters written to the output stream so far by this call to
fprintf. No argument is converted, but one is consumed. If the conversion
specification includes any flags, a field width, or a precision, the behavior is
- undefined.</pre>
- % A % character is written. No argument is converted. The complete
+ undefined.
+<dt> % <dd> A % character is written. No argument is converted. The complete
+ conversion specification shall be %%.
+</dl>
<p><!--para 9 -->
-<pre>
- conversion specification shall be %%.</pre>
If a conversion specification is invalid, the behavior is undefined.<sup><a href="#note248"><b>248)</b></a></sup> If any argument is
not the correct type for the corresponding conversion specification, the behavior is
undefined.
<p><!--para 11 -->
For a and A conversions, if FLT_RADIX is a power of 2, the value is correctly rounded
to a hexadecimal floating number with the given precision.
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 12 -->
For a and A conversions, if FLT_RADIX is not a power of 2 and the result is not exactly
representable in the given precision, the result should be one of the two adjacent numbers
<p><!--para 14 -->
The fprintf function returns the number of characters transmitted, or a negative value
if an output or encoding error occurred.
- Environmental limits
+<h6> Environmental limits</h6>
<p><!--para 15 -->
The number of characters that can be produced by any single conversion shall be at least
4095.
<p><small><a name="note244" href="#note244">244)</a> Binary implementations can choose the hexadecimal digit to the left of the decimal-point character so
that subsequent digits align to nibble (4-bit) boundaries.
</small>
-<p><small><a name="note245" href="#note245">245)</a> The precision p is sufficient to distinguish values of the source type if 16 p-1 > b n where b is
+<p><small><a name="note245" href="#note245">245)</a> The precision p is sufficient to distinguish values of the source type if 16<sup>p-1</sup> > b n where b is
FLT_RADIX and n is the number of base-b digits in the significand of the source type. A smaller p
might suffice depending on the implementation's scheme for determining the digit to the left of the
decimal-point character.
the case of fixed-point conversion by the source value as well.
</small>
-<a name="7.19.6.2" href="#7.19.6.2"><h5>7.19.6.2 The fscanf function</h5></a>
+<h5><a name="7.19.6.2" href="#7.19.6.2">7.19.6.2 The fscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
in the object, the behavior is undefined.
<p><!--para 11 -->
The length modifiers and their meanings are:
- hh Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
- to an argument with type pointer to signed char or unsigned char.</pre>
- h Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
+<dl>
+<dt> hh <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
+ to an argument with type pointer to signed char or unsigned char.
+<dt> h <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
to an argument with type pointer to short int or unsigned short
- int.</pre>
- l (ell) Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
+ int.
+<dt> l (ell) <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
to an argument with type pointer to long int or unsigned long
int; that a following a, A, e, E, f, F, g, or G conversion specifier applies to
an argument with type pointer to double; or that a following c, s, or [
- conversion specifier applies to an argument with type pointer to wchar_t.</pre>
- ll (ell-ell) Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
+ conversion specifier applies to an argument with type pointer to wchar_t.
+<dt> ll (ell-ell)<dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
to an argument with type pointer to long long int or unsigned
- long long int.</pre>
- j Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
- to an argument with type pointer to intmax_t or uintmax_t.</pre>
- z Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
+ long long int.
+<dt> j <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
+ to an argument with type pointer to intmax_t or uintmax_t.
+<dt> z <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
to an argument with type pointer to size_t or the corresponding signed
- integer type.</pre>
- t Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
+ integer type.
+<dt> t <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
to an argument with type pointer to ptrdiff_t or the corresponding
- unsigned integer type.</pre>
- L Specifies that a following a, A, e, E, f, F, g, or G conversion specifier
-<pre>
- applies to an argument with type pointer to long double.</pre>
+ unsigned integer type.
+<dt> L <dd> Specifies that a following a, A, e, E, f, F, g, or G conversion specifier
+ applies to an argument with type pointer to long double.
+</dl>
If a length modifier appears with any conversion specifier other than as specified above,
the behavior is undefined.
<p><!--para 12 -->
The conversion specifiers and their meanings are:
- d Matches an optionally signed decimal integer, whose format is the same as
-<pre>
+<dl>
+<dt> d <dd> Matches an optionally signed decimal integer, whose format is the same as
expected for the subject sequence of the strtol function with the value 10
for the base argument. The corresponding argument shall be a pointer to
- signed integer.</pre>
- i Matches an optionally signed integer, whose format is the same as expected
+ signed integer.
+<dt> i <dd> Matches an optionally signed integer, whose format is the same as expected
<!--page 297 -->
-<pre>
for the subject sequence of the strtol function with the value 0 for the
base argument. The corresponding argument shall be a pointer to signed
- integer.</pre>
- o Matches an optionally signed octal integer, whose format is the same as
-<pre>
+ integer.
+<dt> o <dd> Matches an optionally signed octal integer, whose format is the same as
expected for the subject sequence of the strtoul function with the value 8
for the base argument. The corresponding argument shall be a pointer to
- unsigned integer.</pre>
- u Matches an optionally signed decimal integer, whose format is the same as
-<pre>
+ unsigned integer.
+<dt> u <dd> Matches an optionally signed decimal integer, whose format is the same as
expected for the subject sequence of the strtoul function with the value 10
for the base argument. The corresponding argument shall be a pointer to
- unsigned integer.</pre>
- x Matches an optionally signed hexadecimal integer, whose format is the same
-<pre>
+ unsigned integer.
+<dt> x <dd> Matches an optionally signed hexadecimal integer, whose format is the same
as expected for the subject sequence of the strtoul function with the value
16 for the base argument. The corresponding argument shall be a pointer to
- unsigned integer.</pre>
- a,e,f,g Matches an optionally signed floating-point number, infinity, or NaN, whose
-<pre>
+ unsigned integer.
+<dt> a,e,f,g<dd> Matches an optionally signed floating-point number, infinity, or NaN, whose
format is the same as expected for the subject sequence of the strtod
- function. The corresponding argument shall be a pointer to floating.</pre>
- c Matches a sequence of characters of exactly the number specified by the field
-<pre>
+ function. The corresponding argument shall be a pointer to floating.
+<dt> c <dd> Matches a sequence of characters of exactly the number specified by the field
width (1 if no field width is present in the directive).<sup><a href="#note252"><b>252)</b></a></sup>
If no l length modifier is present, the corresponding argument shall be a
pointer to the initial element of a character array large enough to accept the
initialized to zero before the first multibyte character is converted. The
corresponding argument shall be a pointer to the initial element of an array of
wchar_t large enough to accept the resulting sequence of wide characters.
- No null wide character is added.</pre>
- s Matches a sequence of non-white-space characters.252)
-<pre>
+ No null wide character is added.
+<dt> s <dd> Matches a sequence of non-white-space characters.<sup><a href="#note252"><b>252)</b></a></sup>
If no l length modifier is present, the corresponding argument shall be a
pointer to the initial element of a character array large enough to accept the
sequence and a terminating null character, which will be added automatically.
- If an l length modifier is present, the input shall be a sequence of multibyte</pre>
-
-
+ If an l length modifier is present, the input shall be a sequence of multibyte
<!--page 298 -->
-<pre>
characters that begins in the initial shift state. Each multibyte character is
converted to a wide character as if by a call to the mbrtowc function, with
the conversion state described by an mbstate_t object initialized to zero
before the first multibyte character is converted. The corresponding argument
shall be a pointer to the initial element of an array of wchar_t large enough
to accept the sequence and the terminating null wide character, which will be
- added automatically.</pre>
- [ Matches a nonempty sequence of characters from a set of expected characters
-<pre>
- (the scanset).252)
+ added automatically.
+<dt> [ <dd> Matches a nonempty sequence of characters from a set of expected characters
+ (the scanset).<sup><a href="#note252"><b>252)</b></a></sup>
If no l length modifier is present, the corresponding argument shall be a
pointer to the initial element of a character array large enough to accept the
sequence and a terminating null character, which will be added automatically.
the first following right bracket character is the one that ends the
specification. If a - character is in the scanlist and is not the first, nor the
second where the first character is a ^, nor the last character, the behavior is
- implementation-defined.</pre>
- p Matches an implementation-defined set of sequences, which should be the
+ implementation-defined.
+<dt> p <dd> Matches an implementation-defined set of sequences, which should be the
<!--page 299 -->
-<pre>
same as the set of sequences that may be produced by the %p conversion of
the fprintf function. The corresponding argument shall be a pointer to a
pointer to void. The input item is converted to a pointer value in an
implementation-defined manner. If the input item is a value converted earlier
during the same program execution, the pointer that results shall compare
- equal to that value; otherwise the behavior of the %p conversion is undefined.</pre>
- n No input is consumed. The corresponding argument shall be a pointer to
-<pre>
+ equal to that value; otherwise the behavior of the %p conversion is undefined.
+<dt> n <dd> No input is consumed. The corresponding argument shall be a pointer to
signed integer into which is to be written the number of characters read from
the input stream so far by this call to the fscanf function. Execution of a
%n directive does not increment the assignment count returned at the
completion of execution of the fscanf function. No argument is converted,
but one is consumed. If the conversion specification includes an assignment-
- suppressing character or a field width, the behavior is undefined.</pre>
- % Matches a single % character; no conversion or assignment occurs. The
+ suppressing character or a field width, the behavior is undefined.
+<dt> % <dd> Matches a single % character; no conversion or assignment occurs. The
+ complete conversion specification shall be %%.
+</dl>
<p><!--para 13 -->
-<pre>
- complete conversion specification shall be %%.</pre>
If a conversion specification is invalid, the behavior is undefined.<sup><a href="#note253"><b>253)</b></a></sup>
<p><!--para 14 -->
The conversion specifiers A, E, F, G, and X are also valid and behave the same as,
<p><small><a name="note253" href="#note253">253)</a> See ''future library directions'' (<a href="#7.26.9">7.26.9</a>).
</small>
-<a name="7.19.6.3" href="#7.19.6.3"><h5>7.19.6.3 The printf function</h5></a>
+<h5><a name="7.19.6.3" href="#7.19.6.3">7.19.6.3 The printf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The printf function returns the number of characters transmitted, or a negative value if
an output or encoding error occurred.
-<a name="7.19.6.4" href="#7.19.6.4"><h5>7.19.6.4 The scanf function</h5></a>
+<h5><a name="7.19.6.4" href="#7.19.6.4">7.19.6.4 The scanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
assigned, which can be fewer than provided for, or even zero, in the event of an early
matching failure.
-<a name="7.19.6.5" href="#7.19.6.5"><h5>7.19.6.5 The snprintf function</h5></a>
+<h5><a name="7.19.6.5" href="#7.19.6.5">7.19.6.5 The snprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
value if an encoding error occurred. Thus, the null-terminated output has been
completely written if and only if the returned value is nonnegative and less than n.
-<a name="7.19.6.6" href="#7.19.6.6"><h5>7.19.6.6 The sprintf function</h5></a>
+<h5><a name="7.19.6.6" href="#7.19.6.6">7.19.6.6 The sprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The sprintf function returns the number of characters written in the array, not
counting the terminating null character, or a negative value if an encoding error occurred.
-<a name="7.19.6.7" href="#7.19.6.7"><h5>7.19.6.7 The sscanf function</h5></a>
+<h5><a name="7.19.6.7" href="#7.19.6.7">7.19.6.7 The sscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
early matching failure.
<!--page 304 -->
-<a name="7.19.6.8" href="#7.19.6.8"><h5>7.19.6.8 The vfprintf function</h5></a>
+<h5><a name="7.19.6.8" href="#7.19.6.8">7.19.6.8 The vfprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
vsscanf invoke the va_arg macro, the value of arg after the return is indeterminate.
</small>
-<a name="7.19.6.9" href="#7.19.6.9"><h5>7.19.6.9 The vfscanf function</h5></a>
+<h5><a name="7.19.6.9" href="#7.19.6.9">7.19.6.9 The vfscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vfscanf function is equivalent to fscanf, with the variable argument list
replaced by arg, which shall have been initialized by the va_start macro (and
possibly subsequent va_arg calls). The vfscanf function does not invoke the
- va_end macro.254)
+ va_end macro.<sup><a href="#note254"><b>254)</b></a></sup>
<h6>Returns</h6>
<p><!--para 3 -->
The vfscanf function returns the value of the macro EOF if an input failure occurs
items assigned, which can be fewer than provided for, or even zero, in the event of an
early matching failure.
-<a name="7.19.6.10" href="#7.19.6.10"><h5>7.19.6.10 The vprintf function</h5></a>
+<h5><a name="7.19.6.10" href="#7.19.6.10">7.19.6.10 The vprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vprintf function is equivalent to printf, with the variable argument list
replaced by arg, which shall have been initialized by the va_start macro (and
possibly subsequent va_arg calls). The vprintf function does not invoke the
- va_end macro.254)
+ va_end macro.<sup><a href="#note254"><b>254)</b></a></sup>
<h6>Returns</h6>
<p><!--para 3 -->
The vprintf function returns the number of characters transmitted, or a negative value
if an output or encoding error occurred.
<!--page 306 -->
-<a name="7.19.6.11" href="#7.19.6.11"><h5>7.19.6.11 The vscanf function</h5></a>
+<h5><a name="7.19.6.11" href="#7.19.6.11">7.19.6.11 The vscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vscanf function is equivalent to scanf, with the variable argument list replaced
by arg, which shall have been initialized by the va_start macro (and possibly
subsequent va_arg calls). The vscanf function does not invoke the va_end
- macro.254)
+ macro.<sup><a href="#note254"><b>254)</b></a></sup>
<h6>Returns</h6>
<p><!--para 3 -->
The vscanf function returns the value of the macro EOF if an input failure occurs
items assigned, which can be fewer than provided for, or even zero, in the event of an
early matching failure.
-<a name="7.19.6.12" href="#7.19.6.12"><h5>7.19.6.12 The vsnprintf function</h5></a>
+<h5><a name="7.19.6.12" href="#7.19.6.12">7.19.6.12 The vsnprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vsnprintf function is equivalent to snprintf, with the variable argument list
replaced by arg, which shall have been initialized by the va_start macro (and
possibly subsequent va_arg calls). The vsnprintf function does not invoke the
- va_end macro.254) If copying takes place between objects that overlap, the behavior is
+ va_end macro.<sup><a href="#note254"><b>254)</b></a></sup> If copying takes place between objects that overlap, the behavior is
undefined.
<h6>Returns</h6>
<p><!--para 3 -->
completely written if and only if the returned value is nonnegative and less than n.
<!--page 307 -->
-<a name="7.19.6.13" href="#7.19.6.13"><h5>7.19.6.13 The vsprintf function</h5></a>
+<h5><a name="7.19.6.13" href="#7.19.6.13">7.19.6.13 The vsprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vsprintf function is equivalent to sprintf, with the variable argument list
replaced by arg, which shall have been initialized by the va_start macro (and
possibly subsequent va_arg calls). The vsprintf function does not invoke the
- va_end macro.254) If copying takes place between objects that overlap, the behavior is
+ va_end macro.<sup><a href="#note254"><b>254)</b></a></sup> If copying takes place between objects that overlap, the behavior is
undefined.
<h6>Returns</h6>
<p><!--para 3 -->
The vsprintf function returns the number of characters written in the array, not
counting the terminating null character, or a negative value if an encoding error occurred.
-<a name="7.19.6.14" href="#7.19.6.14"><h5>7.19.6.14 The vsscanf function</h5></a>
+<h5><a name="7.19.6.14" href="#7.19.6.14">7.19.6.14 The vsscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vsscanf function is equivalent to sscanf, with the variable argument list
replaced by arg, which shall have been initialized by the va_start macro (and
possibly subsequent va_arg calls). The vsscanf function does not invoke the
- va_end macro.254)
+ va_end macro.<sup><a href="#note254"><b>254)</b></a></sup>
<h6>Returns</h6>
<p><!--para 3 -->
The vsscanf function returns the value of the macro EOF if an input failure occurs
early matching failure.
<!--page 308 -->
-<a name="7.19.7" href="#7.19.7"><h4>7.19.7 Character input/output functions</h4></a>
+<h4><a name="7.19.7" href="#7.19.7">7.19.7 Character input/output functions</a></h4>
-<a name="7.19.7.1" href="#7.19.7.1"><h5>7.19.7.1 The fgetc function</h5></a>
+<h5><a name="7.19.7.1" href="#7.19.7.1">7.19.7.1 The fgetc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note255" href="#note255">255)</a> An end-of-file and a read error can be distinguished by use of the feof and ferror functions.
</small>
-<a name="7.19.7.2" href="#7.19.7.2"><h5>7.19.7.2 The fgets function</h5></a>
+<h5><a name="7.19.7.2" href="#7.19.7.2">7.19.7.2 The fgets function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 309 -->
-<a name="7.19.7.3" href="#7.19.7.3"><h5>7.19.7.3 The fputc function</h5></a>
+<h5><a name="7.19.7.3" href="#7.19.7.3">7.19.7.3 The fputc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The fputc function returns the character written. If a write error occurs, the error
indicator for the stream is set and fputc returns EOF.
-<a name="7.19.7.4" href="#7.19.7.4"><h5>7.19.7.4 The fputs function</h5></a>
+<h5><a name="7.19.7.4" href="#7.19.7.4">7.19.7.4 The fputs function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The fputs function returns EOF if a write error occurs; otherwise it returns a
nonnegative value.
-<a name="7.19.7.5" href="#7.19.7.5"><h5>7.19.7.5 The getc function</h5></a>
+<h5><a name="7.19.7.5" href="#7.19.7.5">7.19.7.5 The getc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
getc returns EOF. If a read error occurs, the error indicator for the stream is set and
getc returns EOF.
-<a name="7.19.7.6" href="#7.19.7.6"><h5>7.19.7.6 The getchar function</h5></a>
+<h5><a name="7.19.7.6" href="#7.19.7.6">7.19.7.6 The getchar function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
getchar returns EOF. If a read error occurs, the error indicator for the stream is set and
getchar returns EOF.
-<a name="7.19.7.7" href="#7.19.7.7"><h5>7.19.7.7 The gets function</h5></a>
+<h5><a name="7.19.7.7" href="#7.19.7.7">7.19.7.7 The gets function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><b> Forward references</b>: future library directions (<a href="#7.26.9">7.26.9</a>).
<!--page 311 -->
-<a name="7.19.7.8" href="#7.19.7.8"><h5>7.19.7.8 The putc function</h5></a>
+<h5><a name="7.19.7.8" href="#7.19.7.8">7.19.7.8 The putc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The putc function returns the character written. If a write error occurs, the error
indicator for the stream is set and putc returns EOF.
-<a name="7.19.7.9" href="#7.19.7.9"><h5>7.19.7.9 The putchar function</h5></a>
+<h5><a name="7.19.7.9" href="#7.19.7.9">7.19.7.9 The putchar function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The putchar function returns the character written. If a write error occurs, the error
indicator for the stream is set and putchar returns EOF.
-<a name="7.19.7.10" href="#7.19.7.10"><h5>7.19.7.10 The puts function</h5></a>
+<h5><a name="7.19.7.10" href="#7.19.7.10">7.19.7.10 The puts function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
value.
<!--page 312 -->
-<a name="7.19.7.11" href="#7.19.7.11"><h5>7.19.7.11 The ungetc function</h5></a>
+<h5><a name="7.19.7.11" href="#7.19.7.11">7.19.7.11 The ungetc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note256" href="#note256">256)</a> See ''future library directions'' (<a href="#7.26.9">7.26.9</a>).
</small>
-<a name="7.19.8" href="#7.19.8"><h4>7.19.8 Direct input/output functions</h4></a>
+<h4><a name="7.19.8" href="#7.19.8">7.19.8 Direct input/output functions</a></h4>
-<a name="7.19.8.1" href="#7.19.8.1"><h5>7.19.8.1 The fread function</h5></a>
+<h5><a name="7.19.8.1" href="#7.19.8.1">7.19.8.1 The fread function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
fread returns zero and the contents of the array and the state of the stream remain
unchanged.
-<a name="7.19.8.2" href="#7.19.8.2"><h5>7.19.8.2 The fwrite function</h5></a>
+<h5><a name="7.19.8.2" href="#7.19.8.2">7.19.8.2 The fwrite function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
less than nmemb only if a write error is encountered. If size or nmemb is zero,
fwrite returns zero and the state of the stream remains unchanged.
-<a name="7.19.9" href="#7.19.9"><h4>7.19.9 File positioning functions</h4></a>
+<h4><a name="7.19.9" href="#7.19.9">7.19.9 File positioning functions</a></h4>
-<a name="7.19.9.1" href="#7.19.9.1"><h5>7.19.9.1 The fgetpos function</h5></a>
+<h5><a name="7.19.9.1" href="#7.19.9.1">7.19.9.1 The fgetpos function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
returns nonzero and stores an implementation-defined positive value in errno.
<p><b> Forward references</b>: the fsetpos function (<a href="#7.19.9.3">7.19.9.3</a>).
-<a name="7.19.9.2" href="#7.19.9.2"><h5>7.19.9.2 The fseek function</h5></a>
+<h5><a name="7.19.9.2" href="#7.19.9.2">7.19.9.2 The fseek function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The fseek function returns nonzero only for a request that cannot be satisfied.
<p><b> Forward references</b>: the ftell function (<a href="#7.19.9.4">7.19.9.4</a>).
-<a name="7.19.9.3" href="#7.19.9.3"><h5>7.19.9.3 The fsetpos function</h5></a>
+<h5><a name="7.19.9.3" href="#7.19.9.3">7.19.9.3 The fsetpos function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
If successful, the fsetpos function returns zero; on failure, the fsetpos function
returns nonzero and stores an implementation-defined positive value in errno.
-<a name="7.19.9.4" href="#7.19.9.4"><h5>7.19.9.4 The ftell function</h5></a>
+<h5><a name="7.19.9.4" href="#7.19.9.4">7.19.9.4 The ftell function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
for the stream. On failure, the ftell function returns -1L and stores an
implementation-defined positive value in errno.
-<a name="7.19.9.5" href="#7.19.9.5"><h5>7.19.9.5 The rewind function</h5></a>
+<h5><a name="7.19.9.5" href="#7.19.9.5">7.19.9.5 The rewind function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The rewind function returns no value.
-<a name="7.19.10" href="#7.19.10"><h4>7.19.10 Error-handling functions</h4></a>
+<h4><a name="7.19.10" href="#7.19.10">7.19.10 Error-handling functions</a></h4>
-<a name="7.19.10.1" href="#7.19.10.1"><h5>7.19.10.1 The clearerr function</h5></a>
+<h5><a name="7.19.10.1" href="#7.19.10.1">7.19.10.1 The clearerr function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The clearerr function returns no value.
<!--page 317 -->
-<a name="7.19.10.2" href="#7.19.10.2"><h5>7.19.10.2 The feof function</h5></a>
+<h5><a name="7.19.10.2" href="#7.19.10.2">7.19.10.2 The feof function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The feof function returns nonzero if and only if the end-of-file indicator is set for
stream.
-<a name="7.19.10.3" href="#7.19.10.3"><h5>7.19.10.3 The ferror function</h5></a>
+<h5><a name="7.19.10.3" href="#7.19.10.3">7.19.10.3 The ferror function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The ferror function returns nonzero if and only if the error indicator is set for
stream.
-<a name="7.19.10.4" href="#7.19.10.4"><h5>7.19.10.4 The perror function</h5></a>
+<h5><a name="7.19.10.4" href="#7.19.10.4">7.19.10.4 The perror function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><b> Forward references</b>: the strerror function (<a href="#7.21.6.2">7.21.6.2</a>).
<!--page 318 -->
-<a name="7.20" href="#7.20"><h3>7.20 General utilities <stdlib.h></h3></a>
+<h3><a name="7.20" href="#7.20">7.20 General utilities <stdlib.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.20"><stdlib.h></a> declares five types and several functions of general utility, and
defines several macros.<sup><a href="#note257"><b>257)</b></a></sup>
<p><small><a name="note257" href="#note257">257)</a> See ''future library directions'' (<a href="#7.26.10">7.26.10</a>).
</small>
-<a name="7.20.1" href="#7.20.1"><h4>7.20.1 Numeric conversion functions</h4></a>
+<h4><a name="7.20.1" href="#7.20.1">7.20.1 Numeric conversion functions</a></h4>
<p><!--para 1 -->
The functions atof, atoi, atol, and atoll need not affect the value of the integer
expression errno on an error. If the value of the result cannot be represented, the
behavior is undefined.
-<a name="7.20.1.1" href="#7.20.1.1"><h5>7.20.1.1 The atof function</h5></a>
+<h5><a name="7.20.1.1" href="#7.20.1.1">7.20.1.1 The atof function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The atof function returns the converted value.
<p><b> Forward references</b>: the strtod, strtof, and strtold functions (<a href="#7.20.1.3">7.20.1.3</a>).
-<a name="7.20.1.2" href="#7.20.1.2"><h5>7.20.1.2 The atoi, atol, and atoll functions</h5></a>
+<h5><a name="7.20.1.2" href="#7.20.1.2">7.20.1.2 The atoi, atol, and atoll functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
(<a href="#7.20.1.4">7.20.1.4</a>).
<!--page 320 -->
-<a name="7.20.1.3" href="#7.20.1.3"><h5>7.20.1.3 The strtod, strtof, and strtold functions</h5></a>
+<h5><a name="7.20.1.3" href="#7.20.1.3">7.20.1.3 The strtod, strtof, and strtold functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<li> a 0x or 0X, then a nonempty sequence of hexadecimal digits optionally containing a
decimal-point character, then an optional binary exponent part as defined in <a href="#6.4.4.2">6.4.4.2</a>;
<li> INF or INFINITY, ignoring case
-<li> NAN or NAN(n-char-sequenceopt), ignoring case in the NAN part, where:
+<li> NAN or NAN(n-char-sequence<sub>opt</sub>), ignoring case in the NAN part, where:
<pre>
n-char-sequence:
digit
the subject sequence begins with a minus sign, the sequence is interpreted as negated.<sup><a href="#note258"><b>258)</b></a></sup>
A character sequence INF or INFINITY is interpreted as an infinity, if representable in
the return type, else like a floating constant that is too large for the range of the return
- type. A character sequence NAN or NAN(n-char-sequenceopt), is interpreted as a quiet
+ type. A character sequence NAN or NAN(n-char-sequence<sub>opt</sub>), is interpreted as a quiet
NaN, if supported in the return type, else like a subject sequence part that does not have
the expected form; the meaning of the n-char sequences is implementation-defined.<sup><a href="#note259"><b>259)</b></a></sup> A
pointer to the final string is stored in the object pointed to by endptr, provided that
If the subject sequence is empty or does not have the expected form, no conversion is
performed; the value of nptr is stored in the object pointed to by endptr, provided
that endptr is not a null pointer.
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 8 -->
If the subject sequence has the hexadecimal form, FLT_RADIX is not a power of 2, and
the result is not exactly representable, the result should be one of the two numbers in the
to the same internal floating value, but if not will round to adjacent values.
</small>
-<a name="7.20.1.4" href="#7.20.1.4"><h5>7.20.1.4 The strtol, strtoll, strtoul, and strtoull functions</h5></a>
+<h5><a name="7.20.1.4" href="#7.20.1.4">7.20.1.4 The strtol, strtoll, strtoul, and strtoull functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
and sign of the value, if any), and the value of the macro ERANGE is stored in errno.
<!--page 324 -->
-<a name="7.20.2" href="#7.20.2"><h4>7.20.2 Pseudo-random sequence generation functions</h4></a>
+<h4><a name="7.20.2" href="#7.20.2">7.20.2 Pseudo-random sequence generation functions</a></h4>
-<a name="7.20.2.1" href="#7.20.2.1"><h5>7.20.2.1 The rand function</h5></a>
+<h5><a name="7.20.2.1" href="#7.20.2.1">7.20.2.1 The rand function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<h6>Returns</h6>
<p><!--para 4 -->
The rand function returns a pseudo-random integer.
- Environmental limits
+<h6> Environmental limits</h6>
<p><!--para 5 -->
The value of the RAND_MAX macro shall be at least 32767.
-<a name="7.20.2.2" href="#7.20.2.2"><h5>7.20.2.2 The srand function</h5></a>
+<h5><a name="7.20.2.2" href="#7.20.2.2">7.20.2.2 The srand function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
}</pre>
-<a name="7.20.3" href="#7.20.3"><h4>7.20.3 Memory management functions</h4></a>
+<h4><a name="7.20.3" href="#7.20.3">7.20.3 Memory management functions</a></h4>
<p><!--para 1 -->
The order and contiguity of storage allocated by successive calls to the calloc,
malloc, and realloc functions is unspecified. The pointer returned if the allocation
defined: either a null pointer is returned, or the behavior is as if the size were some
nonzero value, except that the returned pointer shall not be used to access an object.
-<a name="7.20.3.1" href="#7.20.3.1"><h5>7.20.3.1 The calloc function</h5></a>
+<h5><a name="7.20.3.1" href="#7.20.3.1">7.20.3.1 The calloc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
constant.
</small>
-<a name="7.20.3.2" href="#7.20.3.2"><h5>7.20.3.2 The free function</h5></a>
+<h5><a name="7.20.3.2" href="#7.20.3.2">7.20.3.2 The free function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The free function returns no value.
-<a name="7.20.3.3" href="#7.20.3.3"><h5>7.20.3.3 The malloc function</h5></a>
+<h5><a name="7.20.3.3" href="#7.20.3.3">7.20.3.3 The malloc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The malloc function returns either a null pointer or a pointer to the allocated space.
-<a name="7.20.3.4" href="#7.20.3.4"><h5>7.20.3.4 The realloc function</h5></a>
+<h5><a name="7.20.3.4" href="#7.20.3.4">7.20.3.4 The realloc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
allocated.
<!--page 327 -->
-<a name="7.20.4" href="#7.20.4"><h4>7.20.4 Communication with the environment</h4></a>
+<h4><a name="7.20.4" href="#7.20.4">7.20.4 Communication with the environment</a></h4>
-<a name="7.20.4.1" href="#7.20.4.1"><h5>7.20.4.1 The abort function</h5></a>
+<h5><a name="7.20.4.1" href="#7.20.4.1">7.20.4.1 The abort function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The abort function does not return to its caller.
-<a name="7.20.4.2" href="#7.20.4.2"><h5>7.20.4.2 The atexit function</h5></a>
+<h5><a name="7.20.4.2" href="#7.20.4.2">7.20.4.2 The atexit function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The atexit function registers the function pointed to by func, to be called without
arguments at normal program termination.
- Environmental limits
+<h6> Environmental limits</h6>
<p><!--para 3 -->
The implementation shall support the registration of at least 32 functions.
<h6>Returns</h6>
The atexit function returns zero if the registration succeeds, nonzero if it fails.
<p><b> Forward references</b>: the exit function (<a href="#7.20.4.3">7.20.4.3</a>).
-<a name="7.20.4.3" href="#7.20.4.3"><h5>7.20.4.3 The exit function</h5></a>
+<h5><a name="7.20.4.3" href="#7.20.4.3">7.20.4.3 The exit function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
other registered functions.
</small>
-<a name="7.20.4.4" href="#7.20.4.4"><h5>7.20.4.4 The _Exit function</h5></a>
+<h5><a name="7.20.4.4" href="#7.20.4.4">7.20.4.4 The _Exit function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 329 -->
-<a name="7.20.4.5" href="#7.20.4.5"><h5>7.20.4.5 The getenv function</h5></a>
+<h5><a name="7.20.4.5" href="#7.20.4.5">7.20.4.5 The getenv function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
overwritten by a subsequent call to the getenv function. If the specified name cannot
be found, a null pointer is returned.
-<a name="7.20.4.6" href="#7.20.4.6"><h5>7.20.4.6 The system function</h5></a>
+<h5><a name="7.20.4.6" href="#7.20.4.6">7.20.4.6 The system function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
function does return, it returns an implementation-defined value.
<!--page 330 -->
-<a name="7.20.5" href="#7.20.5"><h4>7.20.5 Searching and sorting utilities</h4></a>
+<h4><a name="7.20.5" href="#7.20.5">7.20.5 Searching and sorting utilities</a></h4>
<p><!--para 1 -->
These utilities make use of a comparison function to search or sort arrays of unspecified
type. Where an argument declared as size_t nmemb specifies the length of the array
(char *)p < (char *)base + nmemb * size</pre>
</small>
-<a name="7.20.5.1" href="#7.20.5.1"><h5>7.20.5.1 The bsearch function</h5></a>
+<h5><a name="7.20.5.1" href="#7.20.5.1">7.20.5.1 The bsearch function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note264" href="#note264">264)</a> In practice, the entire array is sorted according to the comparison function.
</small>
-<a name="7.20.5.2" href="#7.20.5.2"><h5>7.20.5.2 The qsort function</h5></a>
+<h5><a name="7.20.5.2" href="#7.20.5.2">7.20.5.2 The qsort function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 332 -->
-<a name="7.20.6" href="#7.20.6"><h4>7.20.6 Integer arithmetic functions</h4></a>
+<h4><a name="7.20.6" href="#7.20.6">7.20.6 Integer arithmetic functions</a></h4>
-<a name="7.20.6.1" href="#7.20.6.1"><h5>7.20.6.1 The abs, labs and llabs functions</h5></a>
+<h5><a name="7.20.6.1" href="#7.20.6.1">7.20.6.1 The abs, labs and llabs functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note265" href="#note265">265)</a> The absolute value of the most negative number cannot be represented in two's complement.
</small>
-<a name="7.20.6.2" href="#7.20.6.2"><h5>7.20.6.2 The div, ldiv, and lldiv functions</h5></a>
+<h5><a name="7.20.6.2" href="#7.20.6.2">7.20.6.2 The div, ldiv, and lldiv functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 333 -->
-<a name="7.20.7" href="#7.20.7"><h4>7.20.7 Multibyte/wide character conversion functions</h4></a>
+<h4><a name="7.20.7" href="#7.20.7">7.20.7 Multibyte/wide character conversion functions</a></h4>
<p><!--para 1 -->
The behavior of the multibyte character functions is affected by the LC_CTYPE category
of the current locale. For a state-dependent encoding, each function is placed into its
character codes, but are grouped with an adjacent multibyte character.
</small>
-<a name="7.20.7.1" href="#7.20.7.1"><h5>7.20.7.1 The mblen function</h5></a>
+<h5><a name="7.20.7.1" href="#7.20.7.1">7.20.7.1 The mblen function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 334 -->
-<a name="7.20.7.2" href="#7.20.7.2"><h5>7.20.7.2 The mbtowc function</h5></a>
+<h5><a name="7.20.7.2" href="#7.20.7.2">7.20.7.2 The mbtowc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
In no case will the value returned be greater than n or the value of the MB_CUR_MAX
macro.
-<a name="7.20.7.3" href="#7.20.7.3"><h5>7.20.7.3 The wctomb function</h5></a>
+<h5><a name="7.20.7.3" href="#7.20.7.3">7.20.7.3 The wctomb function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 5 -->
In no case will the value returned be greater than the value of the MB_CUR_MAX macro.
-<a name="7.20.8" href="#7.20.8"><h4>7.20.8 Multibyte/wide string conversion functions</h4></a>
+<h4><a name="7.20.8" href="#7.20.8">7.20.8 Multibyte/wide string conversion functions</a></h4>
<p><!--para 1 -->
The behavior of the multibyte string functions is affected by the LC_CTYPE category of
the current locale.
-<a name="7.20.8.1" href="#7.20.8.1"><h5>7.20.8.1 The mbstowcs function</h5></a>
+<h5><a name="7.20.8.1" href="#7.20.8.1">7.20.8.1 The mbstowcs function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note267" href="#note267">267)</a> The array will not be null-terminated if the value returned is n.
</small>
-<a name="7.20.8.2" href="#7.20.8.2"><h5>7.20.8.2 The wcstombs function</h5></a>
+<h5><a name="7.20.8.2" href="#7.20.8.2">7.20.8.2 The wcstombs function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
If a wide character is encountered that does not correspond to a valid multibyte character,
the wcstombs function returns (size_t)(-1). Otherwise, the wcstombs function
returns the number of bytes modified, not including a terminating null character, if
- any.267)
+ any.<sup><a href="#note267"><b>267)</b></a></sup>
<!--page 337 -->
-<a name="7.21" href="#7.21"><h3>7.21 String handling <string.h></h3></a>
+<h3><a name="7.21" href="#7.21">7.21 String handling <string.h></a></h3>
-<a name="7.21.1" href="#7.21.1"><h4>7.21.1 String function conventions</h4></a>
+<h4><a name="7.21.1" href="#7.21.1">7.21.1 String function conventions</a></h4>
<p><!--para 1 -->
The header <a href="#7.21"><string.h></a> declares one type and several functions, and defines one
macro useful for manipulating arrays of character type and other objects treated as arrays
<p><small><a name="note268" href="#note268">268)</a> See ''future library directions'' (<a href="#7.26.11">7.26.11</a>).
</small>
-<a name="7.21.2" href="#7.21.2"><h4>7.21.2 Copying functions</h4></a>
+<h4><a name="7.21.2" href="#7.21.2">7.21.2 Copying functions</a></h4>
-<a name="7.21.2.1" href="#7.21.2.1"><h5>7.21.2.1 The memcpy function</h5></a>
+<h5><a name="7.21.2.1" href="#7.21.2.1">7.21.2.1 The memcpy function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 338 -->
-<a name="7.21.2.2" href="#7.21.2.2"><h5>7.21.2.2 The memmove function</h5></a>
+<h5><a name="7.21.2.2" href="#7.21.2.2">7.21.2.2 The memmove function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The memmove function returns the value of s1.
-<a name="7.21.2.3" href="#7.21.2.3"><h5>7.21.2.3 The strcpy function</h5></a>
+<h5><a name="7.21.2.3" href="#7.21.2.3">7.21.2.3 The strcpy function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The strcpy function returns the value of s1.
-<a name="7.21.2.4" href="#7.21.2.4"><h5>7.21.2.4 The strncpy function</h5></a>
+<h5><a name="7.21.2.4" href="#7.21.2.4">7.21.2.4 The strncpy function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
not be null-terminated.
</small>
-<a name="7.21.3" href="#7.21.3"><h4>7.21.3 Concatenation functions</h4></a>
+<h4><a name="7.21.3" href="#7.21.3">7.21.3 Concatenation functions</a></h4>
-<a name="7.21.3.1" href="#7.21.3.1"><h5>7.21.3.1 The strcat function</h5></a>
+<h5><a name="7.21.3.1" href="#7.21.3.1">7.21.3.1 The strcat function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The strcat function returns the value of s1.
-<a name="7.21.3.2" href="#7.21.3.2"><h5>7.21.3.2 The strncat function</h5></a>
+<h5><a name="7.21.3.2" href="#7.21.3.2">7.21.3.2 The strncat function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
strlen(s1)+n+1.
</small>
-<a name="7.21.4" href="#7.21.4"><h4>7.21.4 Comparison functions</h4></a>
+<h4><a name="7.21.4" href="#7.21.4">7.21.4 Comparison functions</a></h4>
<p><!--para 1 -->
The sign of a nonzero value returned by the comparison functions memcmp, strcmp,
and strncmp is determined by the sign of the difference between the values of the first
pair of characters (both interpreted as unsigned char) that differ in the objects being
compared.
-<a name="7.21.4.1" href="#7.21.4.1"><h5>7.21.4.1 The memcmp function</h5></a>
+<h5><a name="7.21.4.1" href="#7.21.4.1">7.21.4.1 The memcmp function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
comparison.
</small>
-<a name="7.21.4.2" href="#7.21.4.2"><h5>7.21.4.2 The strcmp function</h5></a>
+<h5><a name="7.21.4.2" href="#7.21.4.2">7.21.4.2 The strcmp function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 341 -->
pointed to by s2.
-<a name="7.21.4.3" href="#7.21.4.3"><h5>7.21.4.3 The strcoll function</h5></a>
+<h5><a name="7.21.4.3" href="#7.21.4.3">7.21.4.3 The strcoll function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
accordingly as the string pointed to by s1 is greater than, equal to, or less than the string
pointed to by s2 when both are interpreted as appropriate to the current locale.
-<a name="7.21.4.4" href="#7.21.4.4"><h5>7.21.4.4 The strncmp function</h5></a>
+<h5><a name="7.21.4.4" href="#7.21.4.4">7.21.4.4 The strncmp function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
accordingly as the possibly null-terminated array pointed to by s1 is greater than, equal
to, or less than the possibly null-terminated array pointed to by s2.
-<a name="7.21.4.5" href="#7.21.4.5"><h5>7.21.4.5 The strxfrm function</h5></a>
+<h5><a name="7.21.4.5" href="#7.21.4.5">7.21.4.5 The strxfrm function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
1 + strxfrm(NULL, s, 0)</pre>
-<a name="7.21.5" href="#7.21.5"><h4>7.21.5 Search functions</h4></a>
+<h4><a name="7.21.5" href="#7.21.5">7.21.5 Search functions</a></h4>
-<a name="7.21.5.1" href="#7.21.5.1"><h5>7.21.5.1 The memchr function</h5></a>
+<h5><a name="7.21.5.1" href="#7.21.5.1">7.21.5.1 The memchr function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The memchr function returns a pointer to the located character, or a null pointer if the
character does not occur in the object.
-<a name="7.21.5.2" href="#7.21.5.2"><h5>7.21.5.2 The strchr function</h5></a>
+<h5><a name="7.21.5.2" href="#7.21.5.2">7.21.5.2 The strchr function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
character does not occur in the string.
<!--page 343 -->
-<a name="7.21.5.3" href="#7.21.5.3"><h5>7.21.5.3 The strcspn function</h5></a>
+<h5><a name="7.21.5.3" href="#7.21.5.3">7.21.5.3 The strcspn function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The strcspn function returns the length of the segment.
-<a name="7.21.5.4" href="#7.21.5.4"><h5>7.21.5.4 The strpbrk function</h5></a>
+<h5><a name="7.21.5.4" href="#7.21.5.4">7.21.5.4 The strpbrk function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The strpbrk function returns a pointer to the character, or a null pointer if no character
from s2 occurs in s1.
-<a name="7.21.5.5" href="#7.21.5.5"><h5>7.21.5.5 The strrchr function</h5></a>
+<h5><a name="7.21.5.5" href="#7.21.5.5">7.21.5.5 The strrchr function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
occur in the string.
<!--page 344 -->
-<a name="7.21.5.6" href="#7.21.5.6"><h5>7.21.5.6 The strspn function</h5></a>
+<h5><a name="7.21.5.6" href="#7.21.5.6">7.21.5.6 The strspn function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The strspn function returns the length of the segment.
-<a name="7.21.5.7" href="#7.21.5.7"><h5>7.21.5.7 The strstr function</h5></a>
+<h5><a name="7.21.5.7" href="#7.21.5.7">7.21.5.7 The strstr function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The strstr function returns a pointer to the located string, or a null pointer if the string
is not found. If s2 points to a string with zero length, the function returns s1.
-<a name="7.21.5.8" href="#7.21.5.8"><h5>7.21.5.8 The strtok function</h5></a>
+<h5><a name="7.21.5.8" href="#7.21.5.8">7.21.5.8 The strtok function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
t = strtok(NULL, "?"); // t is a null pointer</pre>
-<a name="7.21.6" href="#7.21.6"><h4>7.21.6 Miscellaneous functions</h4></a>
+<h4><a name="7.21.6" href="#7.21.6">7.21.6 Miscellaneous functions</a></h4>
-<a name="7.21.6.1" href="#7.21.6.1"><h5>7.21.6.1 The memset function</h5></a>
+<h5><a name="7.21.6.1" href="#7.21.6.1">7.21.6.1 The memset function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The memset function returns the value of s.
<!--page 346 -->
-<a name="7.21.6.2" href="#7.21.6.2"><h5>7.21.6.2 The strerror function</h5></a>
+<h5><a name="7.21.6.2" href="#7.21.6.2">7.21.6.2 The strerror function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
specific. The array pointed to shall not be modified by the program, but may be
overwritten by a subsequent call to the strerror function.
-<a name="7.21.6.3" href="#7.21.6.3"><h5>7.21.6.3 The strlen function</h5></a>
+<h5><a name="7.21.6.3" href="#7.21.6.3">7.21.6.3 The strlen function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
character.
<!--page 347 -->
-<a name="7.22" href="#7.22"><h3>7.22 Type-generic math <tgmath.h></h3></a>
+<h3><a name="7.22" href="#7.22">7.22 Type-generic math <tgmath.h></a></h3>
<p><!--para 1 -->
The header <a href="#7.22"><tgmath.h></a> includes the headers <a href="#7.12"><math.h></a> and <a href="#7.3"><complex.h></a> and
defines several type-generic macros.
<pre>
<a href="#7.12"><math.h></a> <a href="#7.3"><complex.h></a> type-generic
function function macro
+
acos cacos acos
asin casin asin
atan catan atan
functions invoked by use of type-generic macros are shown in the following table:
<!--page 350 -->
<pre>
- macro use invokes
+ macro use invokes
+
exp(n) exp(n), the function
acosh(f) acoshf(f)
sin(d) sin(d), the function
the behavior is undefined.
</small>
-<a name="7.23" href="#7.23"><h3>7.23 Date and time <time.h></h3></a>
+<h3><a name="7.23" href="#7.23">7.23 Date and time <time.h></a></h3>
-<a name="7.23.1" href="#7.23.1"><h4>7.23.1 Components of time</h4></a>
+<h4><a name="7.23.1" href="#7.23.1">7.23.1 Components of time</a></h4>
<p><!--para 1 -->
The header <a href="#7.23"><time.h></a> defines two macros, and declares several types and functions for
manipulating time. Many functions deal with a calendar time that represents the current
<p><small><a name="note274" href="#note274">274)</a> The range [0, 60] for tm_sec allows for a positive leap second.
</small>
-<a name="7.23.2" href="#7.23.2"><h4>7.23.2 Time manipulation functions</h4></a>
+<h4><a name="7.23.2" href="#7.23.2">7.23.2 Time manipulation functions</a></h4>
-<a name="7.23.2.1" href="#7.23.2.1"><h5>7.23.2.1 The clock function</h5></a>
+<h5><a name="7.23.2.1" href="#7.23.2.1">7.23.2.1 The clock function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
the program and its return value subtracted from the value returned by subsequent calls.
</small>
-<a name="7.23.2.2" href="#7.23.2.2"><h5>7.23.2.2 The difftime function</h5></a>
+<h5><a name="7.23.2.2" href="#7.23.2.2">7.23.2.2 The difftime function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 352 -->
-<a name="7.23.2.3" href="#7.23.2.3"><h5>7.23.2.3 The mktime function</h5></a>
+<h5><a name="7.23.2.3" href="#7.23.2.3">7.23.2.3 The mktime function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
causes it to attempt to determine whether Daylight Saving Time is in effect for the specified time.
</small>
-<a name="7.23.2.4" href="#7.23.2.4"><h5>7.23.2.4 The time function</h5></a>
+<h5><a name="7.23.2.4" href="#7.23.2.4">7.23.2.4 The time function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
available. If timer is not a null pointer, the return value is also assigned to the object it
points to.
-<a name="7.23.3" href="#7.23.3"><h4>7.23.3 Time conversion functions</h4></a>
+<h4><a name="7.23.3" href="#7.23.3">7.23.3 Time conversion functions</a></h4>
<p><!--para 1 -->
Except for the strftime function, these functions each return a pointer to one of two
types of static objects: a broken-down time structure or an array of char. Execution of
previous call to any of them. The implementation shall behave as if no other library
functions call these functions.
-<a name="7.23.3.1" href="#7.23.3.1"><h5>7.23.3.1 The asctime function</h5></a>
+<h5><a name="7.23.3.1" href="#7.23.3.1">7.23.3.1 The asctime function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<pre>
Sun Sep 16 01:03:52 1973\n\0</pre>
using the equivalent of the following algorithm.
+<pre>
char *asctime(const struct tm *timeptr)
{
-<pre>
static const char wday_name[7][3] = {
"Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"
};
timeptr->tm_mday, timeptr->tm_hour,
timeptr->tm_min, timeptr->tm_sec,
1900 + timeptr->tm_year);
- return result;</pre>
+ return result;
}
+</pre>
<h6>Returns</h6>
<p><!--para 3 -->
The asctime function returns a pointer to the string.
-<a name="7.23.3.2" href="#7.23.3.2"><h5>7.23.3.2 The ctime function</h5></a>
+<h5><a name="7.23.3.2" href="#7.23.3.2">7.23.3.2 The ctime function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><b> Forward references</b>: the localtime function (<a href="#7.23.3.4">7.23.3.4</a>).
<!--page 355 -->
-<a name="7.23.3.3" href="#7.23.3.3"><h5>7.23.3.3 The gmtime function</h5></a>
+<h5><a name="7.23.3.3" href="#7.23.3.3">7.23.3.3 The gmtime function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The gmtime function returns a pointer to the broken-down time, or a null pointer if the
specified time cannot be converted to UTC.
-<a name="7.23.3.4" href="#7.23.3.4"><h5>7.23.3.4 The localtime function</h5></a>
+<h5><a name="7.23.3.4" href="#7.23.3.4">7.23.3.4 The localtime function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The localtime function returns a pointer to the broken-down time, or a null pointer if
the specified time cannot be converted to local time.
-<a name="7.23.3.5" href="#7.23.3.5"><h5>7.23.3.5 The strftime function</h5></a>
+<h5><a name="7.23.3.5" href="#7.23.3.5">7.23.3.5 The strftime function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
of the current locale and by the values of zero or more members of the broken-down time
structure pointed to by timeptr, as specified in brackets in the description. If any of
the specified values is outside the normal range, the characters stored are unspecified.
- %a is replaced by the locale's abbreviated weekday name. [tm_wday]
- %A is replaced by the locale's full weekday name. [tm_wday]
- %b is replaced by the locale's abbreviated month name. [tm_mon]
- %B is replaced by the locale's full month name. [tm_mon]
- %c is replaced by the locale's appropriate date and time representation. [all specified
-<pre>
- in <a href="#7.23.1">7.23.1</a>]</pre>
- %C is replaced by the year divided by 100 and truncated to an integer, as a decimal
-<pre>
- number (00-99). [tm_year]</pre>
- %d is replaced by the day of the month as a decimal number (01-31). [tm_mday]
- %D is equivalent to ''%m/%d/%y''. [tm_mon, tm_mday, tm_year]
- %e is replaced by the day of the month as a decimal number (1-31); a single digit is
-<pre>
- preceded by a space. [tm_mday]</pre>
- %F is equivalent to ''%Y-%m-%d'' (the ISO 8601 date format). [tm_year, tm_mon,
-<pre>
- tm_mday]</pre>
- %g is replaced by the last 2 digits of the week-based year (see below) as a decimal
-<pre>
- number (00-99). [tm_year, tm_wday, tm_yday]</pre>
- %G is replaced by the week-based year (see below) as a decimal number (e.g., 1997).
-<pre>
- [tm_year, tm_wday, tm_yday]</pre>
- %h is equivalent to ''%b''. [tm_mon]
- %H is replaced by the hour (24-hour clock) as a decimal number (00-23). [tm_hour]
- %I is replaced by the hour (12-hour clock) as a decimal number (01-12). [tm_hour]
- %j is replaced by the day of the year as a decimal number (001-366). [tm_yday]
- %m is replaced by the month as a decimal number (01-12). [tm_mon]
- %M is replaced by the minute as a decimal number (00-59). [tm_min]
- %n is replaced by a new-line character.
- %p is replaced by the locale's equivalent of the AM/PM designations associated with a
-<pre>
- 12-hour clock. [tm_hour]</pre>
- %r is replaced by the locale's 12-hour clock time. [tm_hour, tm_min, tm_sec]
- %R is equivalent to ''%H:%M''. [tm_hour, tm_min]
- %S is replaced by the second as a decimal number (00-60). [tm_sec]
- %t is replaced by a horizontal-tab character.
- %T is equivalent to ''%H:%M:%S'' (the ISO 8601 time format). [tm_hour, tm_min,
+<dl>
+<dt> %a <dd> is replaced by the locale's abbreviated weekday name. [tm_wday]
+<dt> %A <dd> is replaced by the locale's full weekday name. [tm_wday]
+<dt> %b <dd> is replaced by the locale's abbreviated month name. [tm_mon]
+<dt> %B <dd> is replaced by the locale's full month name. [tm_mon]
+<dt> %c <dd> is replaced by the locale's appropriate date and time representation. [all specified
+ in <a href="#7.23.1">7.23.1</a>]
+<dt> %C <dd> is replaced by the year divided by 100 and truncated to an integer, as a decimal
+ number (00-99). [tm_year]
+<dt> %d <dd> is replaced by the day of the month as a decimal number (01-31). [tm_mday]
+<dt> %D <dd> is equivalent to ''%m/%d/%y''. [tm_mon, tm_mday, tm_year]
+<dt> %e <dd> is replaced by the day of the month as a decimal number (1-31); a single digit is
+ preceded by a space. [tm_mday]
+<dt> %F <dd> is equivalent to ''%Y-%m-%d'' (the ISO 8601 date format). [tm_year, tm_mon,
+ tm_mday]
+<dt> %g <dd> is replaced by the last 2 digits of the week-based year (see below) as a decimal
+ number (00-99). [tm_year, tm_wday, tm_yday]
+<dt> %G <dd> is replaced by the week-based year (see below) as a decimal number (e.g., 1997).
+ [tm_year, tm_wday, tm_yday]
+<dt> %h <dd> is equivalent to ''%b''. [tm_mon]
+<dt> %H <dd> is replaced by the hour (24-hour clock) as a decimal number (00-23). [tm_hour]
+<dt> %I <dd> is replaced by the hour (12-hour clock) as a decimal number (01-12). [tm_hour]
+<dt> %j <dd> is replaced by the day of the year as a decimal number (001-366). [tm_yday]
+<dt> %m <dd> is replaced by the month as a decimal number (01-12). [tm_mon]
+<dt> %M <dd> is replaced by the minute as a decimal number (00-59). [tm_min]
+<dt> %n <dd> is replaced by a new-line character.
+<dt> %p <dd> is replaced by the locale's equivalent of the AM/PM designations associated with a
+ 12-hour clock. [tm_hour]
+<dt> %r <dd> is replaced by the locale's 12-hour clock time. [tm_hour, tm_min, tm_sec]
+<dt> %R <dd> is equivalent to ''%H:%M''. [tm_hour, tm_min]
+<dt> %S <dd> is replaced by the second as a decimal number (00-60). [tm_sec]
+<dt> %t <dd> is replaced by a horizontal-tab character.
+<dt> %T <dd> is equivalent to ''%H:%M:%S'' (the ISO 8601 time format). [tm_hour, tm_min,
<!--page 357 -->
-<pre>
- tm_sec]</pre>
- %u is replaced by the ISO 8601 weekday as a decimal number (1-7), where Monday
-<pre>
- is 1. [tm_wday]</pre>
- %U is replaced by the week number of the year (the first Sunday as the first day of week
-<pre>
- 1) as a decimal number (00-53). [tm_year, tm_wday, tm_yday]</pre>
- %V is replaced by the ISO 8601 week number (see below) as a decimal number
-<pre>
- (01-53). [tm_year, tm_wday, tm_yday]</pre>
- %w is replaced by the weekday as a decimal number (0-6), where Sunday is 0.
-<pre>
- [tm_wday]</pre>
- %W is replaced by the week number of the year (the first Monday as the first day of
-<pre>
- week 1) as a decimal number (00-53). [tm_year, tm_wday, tm_yday]</pre>
- %x is replaced by the locale's appropriate date representation. [all specified in <a href="#7.23.1">7.23.1</a>]
- %X is replaced by the locale's appropriate time representation. [all specified in <a href="#7.23.1">7.23.1</a>]
- %y is replaced by the last 2 digits of the year as a decimal number (00-99).
-<pre>
- [tm_year]</pre>
- %Y is replaced by the year as a decimal number (e.g., 1997). [tm_year]
- %z is replaced by the offset from UTC in the ISO 8601 format ''-0430'' (meaning 4
-<pre>
+ tm_sec]
+<dt> %u <dd>is replaced by the ISO 8601 weekday as a decimal number (1-7), where Monday
+ is 1. [tm_wday]
+<dt> %U <dd> is replaced by the week number of the year (the first Sunday as the first day of week
+ 1) as a decimal number (00-53). [tm_year, tm_wday, tm_yday]
+<dt> %V <dd> is replaced by the ISO 8601 week number (see below) as a decimal number
+ (01-53). [tm_year, tm_wday, tm_yday]
+<dt> %w <dd> is replaced by the weekday as a decimal number (0-6), where Sunday is 0.
+ [tm_wday]
+<dt> %W <dd> is replaced by the week number of the year (the first Monday as the first day of
+ week 1) as a decimal number (00-53). [tm_year, tm_wday, tm_yday]
+<dt> %x <dd> is replaced by the locale's appropriate date representation. [all specified in <a href="#7.23.1">7.23.1</a>]
+<dt> %X <dd> is replaced by the locale's appropriate time representation. [all specified in <a href="#7.23.1">7.23.1</a>]
+<dt> %y <dd> is replaced by the last 2 digits of the year as a decimal number (00-99).
+ [tm_year]
+<dt> %Y <dd> is replaced by the year as a decimal number (e.g., 1997). [tm_year]
+<dt> %z <dd> is replaced by the offset from UTC in the ISO 8601 format ''-0430'' (meaning 4
hours 30 minutes behind UTC, west of Greenwich), or by no characters if no time
- zone is determinable. [tm_isdst]</pre>
- %Z is replaced by the locale's time zone name or abbreviation, or by no characters if no
-<pre>
- time zone is determinable. [tm_isdst]</pre>
- %% is replaced by %.
+ zone is determinable. [tm_isdst]
+<dt> %Z <dd> is replaced by the locale's time zone name or abbreviation, or by no characters if no
+ time zone is determinable. [tm_isdst]
+<dt> %% <dd> is replaced by %.
+</dl>
<p><!--para 4 -->
Some conversion specifiers can be modified by the inclusion of an E or O modifier
character to indicate an alternative format or specification. If the alternative format or
specification does not exist for the current locale, the modifier is ignored.
- %Ec is replaced by the locale's alternative date and time representation.
- %EC is replaced by the name of the base year (period) in the locale's alternative
-<pre>
- representation.</pre>
- %Ex is replaced by the locale's alternative date representation.
- %EX is replaced by the locale's alternative time representation.
- %Ey is replaced by the offset from %EC (year only) in the locale's alternative
-<pre>
- representation.</pre>
- %EY is replaced by the locale's full alternative year representation.
- %Od is replaced by the day of the month, using the locale's alternative numeric symbols
-<pre>
+<dl>
+<dt> %Ec <dd> is replaced by the locale's alternative date and time representation.
+<dt> %EC <dd>is replaced by the name of the base year (period) in the locale's alternative
+ representation.
+<dt> %Ex <dd>is replaced by the locale's alternative date representation.
+<dt> %EX <dd>is replaced by the locale's alternative time representation.
+<dt> %Ey <dd>is replaced by the offset from %EC (year only) in the locale's alternative
+ representation.
+<dt> %EY <dd>is replaced by the locale's full alternative year representation.
+<dt> %Od <dd>is replaced by the day of the month, using the locale's alternative numeric symbols
(filled as needed with leading zeros, or with leading spaces if there is no alternative
- symbol for zero).</pre>
- %Oe is replaced by the day of the month, using the locale's alternative numeric symbols
-<pre>
- (filled as needed with leading spaces).</pre>
- %OH is replaced by the hour (24-hour clock), using the locale's alternative numeric
+ symbol for zero).
+<dt> %Oe <dd>is replaced by the day of the month, using the locale's alternative numeric symbols
+ (filled as needed with leading spaces).
+<dt> %OH <dd>is replaced by the hour (24-hour clock), using the locale's alternative numeric
<!--page 358 -->
-<pre>
- symbols.</pre>
- %OI is replaced by the hour (12-hour clock), using the locale's alternative numeric
-<pre>
- symbols.</pre>
- %Om is replaced by the month, using the locale's alternative numeric symbols.
- %OM is replaced by the minutes, using the locale's alternative numeric symbols.
- %OS is replaced by the seconds, using the locale's alternative numeric symbols.
- %Ou is replaced by the ISO 8601 weekday as a number in the locale's alternative
-<pre>
- representation, where Monday is 1.</pre>
- %OU is replaced by the week number, using the locale's alternative numeric symbols.
- %OV is replaced by the ISO 8601 week number, using the locale's alternative numeric
-<pre>
- symbols.</pre>
- %Ow is replaced by the weekday as a number, using the locale's alternative numeric
-<pre>
- symbols.</pre>
- %OW is replaced by the week number of the year, using the locale's alternative numeric
-<pre>
- symbols.</pre>
- %Oy is replaced by the last 2 digits of the year, using the locale's alternative numeric
+ symbols.
+<dt> %OI <dd>is replaced by the hour (12-hour clock), using the locale's alternative numeric
+ symbols.
+<dt> %Om <dd>is replaced by the month, using the locale's alternative numeric symbols.
+<dt> %OM <dd>is replaced by the minutes, using the locale's alternative numeric symbols.
+<dt> %OS <dd>is replaced by the seconds, using the locale's alternative numeric symbols.
+<dt> %Ou <dd>is replaced by the ISO 8601 weekday as a number in the locale's alternative
+ representation, where Monday is 1.
+<dt> %OU <dd>is replaced by the week number, using the locale's alternative numeric symbols.
+<dt> %OV <dd>is replaced by the ISO 8601 week number, using the locale's alternative numeric
+ symbols.
+<dt> %Ow <dd>is replaced by the weekday as a number, using the locale's alternative numeric
+ symbols.
+<dt> %OW <dd>is replaced by the week number of the year, using the locale's alternative numeric
+ symbols.
+<dt> %Oy <dd>is replaced by the last 2 digits of the year, using the locale's alternative numeric
+ symbols.
+</dl>
<p><!--para 5 -->
-<pre>
- symbols.</pre>
%g, %G, and %V give values according to the ISO 8601 week-based year. In this system,
weeks begin on a Monday and week 1 of the year is the week that includes January 4th,
which is also the week that includes the first Thursday of the year, and is also the first
<p><!--para 7 -->
In the "C" locale, the E and O modifiers are ignored and the replacement strings for the
following specifiers are:
- %a the first three characters of %A.
- %A one of ''Sunday'', ''Monday'', ... , ''Saturday''.
- %b the first three characters of %B.
- %B one of ''January'', ''February'', ... , ''December''.
- %c equivalent to ''%a %b %e %T %Y''.
- %p one of ''AM'' or ''PM''.
- %r equivalent to ''%I:%M:%S %p''.
- %x equivalent to ''%m/%d/%y''.
- %X equivalent to %T.
- %Z implementation-defined.
+<dl>
+<dt> %a <dd> the first three characters of %A.
+<dt> %A <dd> one of ''Sunday'', ''Monday'', ... , ''Saturday''.
+<dt> %b <dd> the first three characters of %B.
+<dt> %B <dd> one of ''January'', ''February'', ... , ''December''.
+<dt> %c <dd> equivalent to ''%a %b %e %T %Y''.
+<dt> %p <dd> one of ''AM'' or ''PM''.
+<dt> %r <dd> equivalent to ''%I:%M:%S %p''.
+<dt> %x <dd> equivalent to ''%m/%d/%y''.
+<dt> %X <dd> equivalent to %T.
+<dt> %Z <dd> implementation-defined.
+</dl>
<!--page 359 -->
<h6>Returns</h6>
<p><!--para 8 -->
zero is returned and the contents of the array are indeterminate.
<!--page 360 -->
-<a name="7.24" href="#7.24"><h3>7.24 Extended multibyte and wide character utilities <wchar.h></h3></a>
+<h3><a name="7.24" href="#7.24">7.24 Extended multibyte and wide character utilities <wchar.h></a></h3>
-<a name="7.24.1" href="#7.24.1"><h4>7.24.1 Introduction</h4></a>
+<h4><a name="7.24.1" href="#7.24.1">7.24.1 Introduction</a></h4>
<p><!--para 1 -->
The header <a href="#7.24"><wchar.h></a> declares four data types, one tag, four macros, and many
functions.<sup><a href="#note277"><b>277)</b></a></sup>
<p><small><a name="note279" href="#note279">279)</a> The value of the macro WEOF may differ from that of EOF and need not be negative.
</small>
-<a name="7.24.2" href="#7.24.2"><h4>7.24.2 Formatted wide character input/output functions</h4></a>
+<h4><a name="7.24.2" href="#7.24.2">7.24.2 Formatted wide character input/output functions</a></h4>
<p><!--para 1 -->
The formatted wide character input/output functions shall behave as if there is a sequence
point after the actions associated with each specifier.<sup><a href="#note280"><b>280)</b></a></sup>
<p><small><a name="note280" href="#note280">280)</a> The fwprintf functions perform writes to memory for the %n specifier.
</small>
-<a name="7.24.2.1" href="#7.24.2.1"><h5>7.24.2.1 The fwprintf function</h5></a>
+<h5><a name="7.24.2.1" href="#7.24.2.1">7.24.2.1 The fwprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
precision were omitted.
<p><!--para 6 -->
The flag wide characters and their meanings are:
- - The result of the conversion is left-justified within the field. (It is right-justified if
-<pre>
- this flag is not specified.)</pre>
- + The result of a signed conversion always begins with a plus or minus sign. (It
-<pre>
+<dl>
+<dt> - <dd> The result of the conversion is left-justified within the field. (It is right-justified if
+ this flag is not specified.)
+<dt> + <dd> The result of a signed conversion always begins with a plus or minus sign. (It
begins with a sign only when a negative value is converted if this flag is not
- specified.)<sup><a href="#note282"><b>282)</b></a></sup></pre>
- space If the first wide character of a signed conversion is not a sign, or if a signed
-<pre>
+ specified.)<sup><a href="#note282"><b>282)</b></a></sup>
+<dt> space<dd> If the first wide character of a signed conversion is not a sign, or if a signed
conversion results in no wide characters, a space is prefixed to the result. If the
- space and + flags both appear, the space flag is ignored.</pre>
- # The result is converted to an ''alternative form''. For o conversion, it increases
-<pre>
+ space and + flags both appear, the space flag is ignored.
+<dt> # <dd> The result is converted to an ''alternative form''. For o conversion, it increases
the precision, if and only if necessary, to force the first digit of the result to be a
zero (if the value and precision are both 0, a single 0 is printed). For x (or X)
- conversion, a nonzero result has 0x (or 0X) prefixed to it. For a, A, e, E, f, F, g,</pre>
+ conversion, a nonzero result has 0x (or 0X) prefixed to it. For a, A, e, E, f, F, g,
<!--page 363 -->
-<pre>
and G conversions, the result of converting a floating-point number always
contains a decimal-point wide character, even if no digits follow it. (Normally, a
decimal-point wide character appears in the result of these conversions only if a
digit follows it.) For g and G conversions, trailing zeros are not removed from the
- result. For other conversions, the behavior is undefined.</pre>
- 0 For d, i, o, u, x, X, a, A, e, E, f, F, g, and G conversions, leading zeros
-<p><!--para 7 -->
-<pre>
+ result. For other conversions, the behavior is undefined.
+<dt> 0 <dd> For d, i, o, u, x, X, a, A, e, E, f, F, g, and G conversions, leading zeros
(following any indication of sign or base) are used to pad to the field width rather
than performing space padding, except when converting an infinity or NaN. If the
0 and - flags both appear, the 0 flag is ignored. For d, i, o, u, x, and X
conversions, if a precision is specified, the 0 flag is ignored. For other
- conversions, the behavior is undefined.</pre>
+ conversions, the behavior is undefined.
+</dl>
+<p><!--para 7 -->
The length modifiers and their meanings are:
- hh Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+<dl>
+<dt> hh <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
signed char or unsigned char argument (the argument will have
been promoted according to the integer promotions, but its value shall be
converted to signed char or unsigned char before printing); or that
a following n conversion specifier applies to a pointer to a signed char
- argument.</pre>
- h Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+ argument.
+<dt> h <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
short int or unsigned short int argument (the argument will
have been promoted according to the integer promotions, but its value shall
be converted to short int or unsigned short int before printing);
or that a following n conversion specifier applies to a pointer to a short
- int argument.</pre>
- l (ell) Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+ int argument.
+<dt> l (ell)<dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
long int or unsigned long int argument; that a following n
conversion specifier applies to a pointer to a long int argument; that a
following c conversion specifier applies to a wint_t argument; that a
following s conversion specifier applies to a pointer to a wchar_t
argument; or has no effect on a following a, A, e, E, f, F, g, or G conversion
- specifier.</pre>
- ll (ell-ell) Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+ specifier.
+<dt> ll (ell-ell)<dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
long long int or unsigned long long int argument; or that a
following n conversion specifier applies to a pointer to a long long int
- argument.</pre>
- j Specifies that a following d, i, o, u, x, or X conversion specifier applies to
+ argument.
+<dt> j <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to
<!--page 364 -->
-<pre>
an intmax_t or uintmax_t argument; or that a following n conversion
- specifier applies to a pointer to an intmax_t argument.</pre>
- z Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+ specifier applies to a pointer to an intmax_t argument.
+<dt> z <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
size_t or the corresponding signed integer type argument; or that a
following n conversion specifier applies to a pointer to a signed integer type
- corresponding to size_t argument.</pre>
- t Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
-<pre>
+ corresponding to size_t argument.
+<dt> t <dd> Specifies that a following d, i, o, u, x, or X conversion specifier applies to a
ptrdiff_t or the corresponding unsigned integer type argument; or that a
following n conversion specifier applies to a pointer to a ptrdiff_t
- argument.</pre>
- L Specifies that a following a, A, e, E, f, F, g, or G conversion specifier
-<pre>
- applies to a long double argument.</pre>
+ argument.
+<dt> L <dd> Specifies that a following a, A, e, E, f, F, g, or G conversion specifier
+ applies to a long double argument.
+</dl>
If a length modifier appears with any conversion specifier other than as specified above,
the behavior is undefined.
<p><!--para 8 -->
The conversion specifiers and their meanings are:
- d,i The int argument is converted to signed decimal in the style [-]dddd. The
-<pre>
+<dl>
+<dt> d,i <dd> The int argument is converted to signed decimal in the style [-]dddd. The
precision specifies the minimum number of digits to appear; if the value
being converted can be represented in fewer digits, it is expanded with
leading zeros. The default precision is 1. The result of converting a zero
- value with a precision of zero is no wide characters.</pre>
- o,u,x,X The unsigned int argument is converted to unsigned octal (o), unsigned
-<pre>
+ value with a precision of zero is no wide characters.
+<dt> o,u,x,X<dd> The unsigned int argument is converted to unsigned octal (o), unsigned
decimal (u), or unsigned hexadecimal notation (x or X) in the style dddd; the
letters abcdef are used for x conversion and the letters ABCDEF for X
conversion. The precision specifies the minimum number of digits to appear;
if the value being converted can be represented in fewer digits, it is expanded
with leading zeros. The default precision is 1. The result of converting a
- zero value with a precision of zero is no wide characters.</pre>
- f,F A double argument representing a floating-point number is converted to
+ zero value with a precision of zero is no wide characters.
+<dt> f,F <dd> A double argument representing a floating-point number is converted to
<!--page 365 -->
-<pre>
decimal notation in the style [-]ddd.ddd, where the number of digits after
the decimal-point wide character is equal to the precision specification. If the
precision is missing, it is taken as 6; if the precision is zero and the # flag is
[-]nan or [-]nan(n-wchar-sequence) -- which style, and the meaning of
any n-wchar-sequence, is implementation-defined. The F conversion
specifier produces INF, INFINITY, or NAN instead of inf, infinity, or
- nan, respectively.<sup><a href="#note283"><b>283)</b></a></sup></pre>
- e,E A double argument representing a floating-point number is converted in the
-<pre>
+ nan, respectively.<sup><a href="#note283"><b>283)</b></a></sup>
+<dt> e,E <dd> A double argument representing a floating-point number is converted in the
style [-]d.ddd e(+-)dd, where there is one digit (which is nonzero if the
argument is nonzero) before the decimal-point wide character and the number
of digits after it is equal to the precision; if the precision is missing, it is taken
and only as many more digits as necessary to represent the exponent. If the
value is zero, the exponent is zero.
A double argument representing an infinity or NaN is converted in the style
- of an f or F conversion specifier.</pre>
- g,G A double argument representing a floating-point number is converted in
-<pre>
+ of an f or F conversion specifier.
+<dt> g,G <dd> A double argument representing a floating-point number is converted in
style f or e (or in style F or E in the case of a G conversion specifier),
depending on the value converted and the precision. Let P equal the
precision if nonzero, 6 if the precision is omitted, or 1 if the precision is zero.
Then, if a conversion with style E would have an exponent of X :
- -- if P > X >= -4, the conversion is with style f (or F) and precision
+ <ul>
+ <li> if P > X >= -4, the conversion is with style f (or F) and precision
P - (X + 1).
- -- otherwise, the conversion is with style e (or E) and precision P - 1.
+ <li> otherwise, the conversion is with style e (or E) and precision P - 1.
+ </ul>
Finally, unless the # flag is used, any trailing zeros are removed from the
fractional portion of the result and the decimal-point wide character is
removed if there is no fractional portion remaining.
A double argument representing an infinity or NaN is converted in the style
- of an f or F conversion specifier.</pre>
- a,A A double argument representing a floating-point number is converted in the
-<pre>
+ of an f or F conversion specifier.
+<dt> a,A <dd> A double argument representing a floating-point number is converted in the
style [-]0xh.hhhh p(+-)d, where there is one hexadecimal digit (which is
nonzero if the argument is a normalized floating-point number and is
otherwise unspecified) before the decimal-point wide character<sup><a href="#note284"><b>284)</b></a></sup> and the
number of hexadecimal digits after it is equal to the precision; if the precision
- is missing and FLT_RADIX is a power of 2, then the precision is sufficient</pre>
-
-
+ is missing and FLT_RADIX is a power of 2, then the precision is sufficient
<!--page 366 -->
-<pre>
for an exact representation of the value; if the precision is missing and
FLT_RADIX is not a power of 2, then the precision is sufficient to
distinguish<sup><a href="#note285"><b>285)</b></a></sup> values of type double, except that trailing zeros may be
represent the decimal exponent of 2. If the value is zero, the exponent is
zero.
A double argument representing an infinity or NaN is converted in the style
- of an f or F conversion specifier.</pre>
- c If no l length modifier is present, the int argument is converted to a wide
-<pre>
+ of an f or F conversion specifier.
+<dt> c <dd> If no l length modifier is present, the int argument is converted to a wide
character as if by calling btowc and the resulting wide character is written.
If an l length modifier is present, the wint_t argument is converted to
- wchar_t and written.</pre>
- s If no l length modifier is present, the argument shall be a pointer to the initial
-<pre>
+ wchar_t and written.
+<dt> s <dd> If no l length modifier is present, the argument shall be a pointer to the initial
element of a character array containing a multibyte character sequence
beginning in the initial shift state. Characters from the array are converted as
if by repeated calls to the mbrtowc function, with the conversion state
written up to (but not including) a terminating null wide character. If the
precision is specified, no more than that many wide characters are written. If
the precision is not specified or is greater than the size of the array, the array
- shall contain a null wide character.</pre>
- p The argument shall be a pointer to void. The value of the pointer is
-<pre>
- converted to a sequence of printing wide characters, in an implementation-</pre>
-
+ shall contain a null wide character.
+<dt> p <dd> The argument shall be a pointer to void. The value of the pointer is
+ converted to a sequence of printing wide characters, in an implementation-
<!--page 367 -->
-<pre>
- defined manner.</pre>
- n The argument shall be a pointer to signed integer into which is written the
-<pre>
+ defined manner.
+<dt> n <dd> The argument shall be a pointer to signed integer into which is written the
number of wide characters written to the output stream so far by this call to
fwprintf. No argument is converted, but one is consumed. If the
conversion specification includes any flags, a field width, or a precision, the
- behavior is undefined.</pre>
- % A % wide character is written. No argument is converted. The complete
+ behavior is undefined.
+<dt> % <dd> A % wide character is written. No argument is converted. The complete
+ conversion specification shall be %%.
+</dl>
<p><!--para 9 -->
-<pre>
- conversion specification shall be %%.</pre>
If a conversion specification is invalid, the behavior is undefined.<sup><a href="#note286"><b>286)</b></a></sup> If any argument is
not the correct type for the corresponding conversion specification, the behavior is
undefined.
<p><!--para 11 -->
For a and A conversions, if FLT_RADIX is a power of 2, the value is correctly rounded
to a hexadecimal floating number with the given precision.
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 12 -->
For a and A conversions, if FLT_RADIX is not a power of 2 and the result is not exactly
representable in the given precision, the result should be one of the two adjacent numbers
value if an output or encoding error occurred.
<!--page 368 -->
- Environmental limits
+<h6> Environmental limits</h6>
<p><!--para 15 -->
The number of wide characters that can be produced by any single conversion shall be at
least 4095.
<p><small><a name="note284" href="#note284">284)</a> Binary implementations can choose the hexadecimal digit to the left of the decimal-point wide
character so that subsequent digits align to nibble (4-bit) boundaries.
</small>
-<p><small><a name="note285" href="#note285">285)</a> The precision p is sufficient to distinguish values of the source type if 16 p-1 > b n where b is
+<p><small><a name="note285" href="#note285">285)</a> The precision p is sufficient to distinguish values of the source type if 16<sup>p-1</sup> > b n where b is
FLT_RADIX and n is the number of base-b digits in the significand of the source type. A smaller p
might suffice depending on the implementation's scheme for determining the digit to the left of the
decimal-point wide character.
the case of fixed-point conversion by the source value as well.
</small>
-<a name="7.24.2.2" href="#7.24.2.2"><h5>7.24.2.2 The fwscanf function</h5></a>
+<h5><a name="7.24.2.2" href="#7.24.2.2">7.24.2.2 The fwscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
represented in the object, the behavior is undefined.
<p><!--para 11 -->
The length modifiers and their meanings are:
- hh Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
- to an argument with type pointer to signed char or unsigned char.</pre>
- h Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
+<dl>
+<dt> hh <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
+ to an argument with type pointer to signed char or unsigned char.
+<dt> h <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
to an argument with type pointer to short int or unsigned short
- int.</pre>
- l (ell) Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
+ int.
+<dt> l (ell) <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
to an argument with type pointer to long int or unsigned long
int; that a following a, A, e, E, f, F, g, or G conversion specifier applies to
an argument with type pointer to double; or that a following c, s, or [
- conversion specifier applies to an argument with type pointer to wchar_t.</pre>
- ll (ell-ell) Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
+ conversion specifier applies to an argument with type pointer to wchar_t.
+<dt> ll (ell-ell)<dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
to an argument with type pointer to long long int or unsigned
- long long int.</pre>
- j Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
- to an argument with type pointer to intmax_t or uintmax_t.</pre>
- z Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
+ long long int.
+<dt> j <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
+ to an argument with type pointer to intmax_t or uintmax_t.
+<dt> z <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
to an argument with type pointer to size_t or the corresponding signed
- integer type.</pre>
- t Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
-<pre>
+ integer type.
+<dt> t <dd> Specifies that a following d, i, o, u, x, X, or n conversion specifier applies
to an argument with type pointer to ptrdiff_t or the corresponding
- unsigned integer type.</pre>
- L Specifies that a following a, A, e, E, f, F, g, or G conversion specifier
-<pre>
- applies to an argument with type pointer to long double.</pre>
+ unsigned integer type.
+<dt> L <dd> Specifies that a following a, A, e, E, f, F, g, or G conversion specifier
+ applies to an argument with type pointer to long double.
+</dl>
If a length modifier appears with any conversion specifier other than as specified above,
the behavior is undefined.
<p><!--para 12 -->
The conversion specifiers and their meanings are:
- d Matches an optionally signed decimal integer, whose format is the same as
-<pre>
+<dl>
+<dt> d <dd> Matches an optionally signed decimal integer, whose format is the same as
expected for the subject sequence of the wcstol function with the value 10
for the base argument. The corresponding argument shall be a pointer to
- signed integer.</pre>
- i Matches an optionally signed integer, whose format is the same as expected
+ signed integer.
+<dt> i <dd> Matches an optionally signed integer, whose format is the same as expected
<!--page 371 -->
-<pre>
for the subject sequence of the wcstol function with the value 0 for the
base argument. The corresponding argument shall be a pointer to signed
- integer.</pre>
- o Matches an optionally signed octal integer, whose format is the same as
-<pre>
+ integer.
+<dt> o <dd> Matches an optionally signed octal integer, whose format is the same as
expected for the subject sequence of the wcstoul function with the value 8
for the base argument. The corresponding argument shall be a pointer to
- unsigned integer.</pre>
- u Matches an optionally signed decimal integer, whose format is the same as
-<pre>
+ unsigned integer.
+<dt> u <dd> Matches an optionally signed decimal integer, whose format is the same as
expected for the subject sequence of the wcstoul function with the value 10
for the base argument. The corresponding argument shall be a pointer to
- unsigned integer.</pre>
- x Matches an optionally signed hexadecimal integer, whose format is the same
-<pre>
+ unsigned integer.
+<dt> x <dd> Matches an optionally signed hexadecimal integer, whose format is the same
as expected for the subject sequence of the wcstoul function with the value
16 for the base argument. The corresponding argument shall be a pointer to
- unsigned integer.</pre>
- a,e,f,g Matches an optionally signed floating-point number, infinity, or NaN, whose
-<pre>
+ unsigned integer.
+<dt> a,e,f,g<dd> Matches an optionally signed floating-point number, infinity, or NaN, whose
format is the same as expected for the subject sequence of the wcstod
- function. The corresponding argument shall be a pointer to floating.</pre>
- c Matches a sequence of wide characters of exactly the number specified by the
-<pre>
+ function. The corresponding argument shall be a pointer to floating.
+<dt> c <dd> Matches a sequence of wide characters of exactly the number specified by the
field width (1 if no field width is present in the directive).
If no l length modifier is present, characters from the input field are
converted as if by repeated calls to the wcrtomb function, with the
accept the sequence. No null character is added.
If an l length modifier is present, the corresponding argument shall be a
pointer to the initial element of an array of wchar_t large enough to accept
- the sequence. No null wide character is added.</pre>
- s Matches a sequence of non-white-space wide characters.
+ the sequence. No null wide character is added.
+<dt> s <dd> Matches a sequence of non-white-space wide characters.
<!--page 372 -->
-<pre>
If no l length modifier is present, characters from the input field are
converted as if by repeated calls to the wcrtomb function, with the
conversion state described by an mbstate_t object initialized to zero
If an l length modifier is present, the corresponding argument shall be a
pointer to the initial element of an array of wchar_t large enough to accept
the sequence and the terminating null wide character, which will be added
- automatically.</pre>
- [ Matches a nonempty sequence of wide characters from a set of expected
-<pre>
+ automatically.
+<dt> [ <dd> Matches a nonempty sequence of wide characters from a set of expected
characters (the scanset).
If no l length modifier is present, characters from the input field are
converted as if by repeated calls to the wcrtomb function, with the
the specification; otherwise the first following right bracket wide character is
the one that ends the specification. If a - wide character is in the scanlist and
is not the first, nor the second where the first wide character is a ^, nor the
- last character, the behavior is implementation-defined.</pre>
- p Matches an implementation-defined set of sequences, which should be the
-<pre>
+ last character, the behavior is implementation-defined.
+<dt> p <dd> Matches an implementation-defined set of sequences, which should be the
same as the set of sequences that may be produced by the %p conversion of
the fwprintf function. The corresponding argument shall be a pointer to a
pointer to void. The input item is converted to a pointer value in an
implementation-defined manner. If the input item is a value converted earlier
during the same program execution, the pointer that results shall compare
- equal to that value; otherwise the behavior of the %p conversion is undefined.</pre>
- n No input is consumed. The corresponding argument shall be a pointer to
+ equal to that value; otherwise the behavior of the %p conversion is undefined.
+<dt> n <dd> No input is consumed. The corresponding argument shall be a pointer to
<!--page 373 -->
-<pre>
signed integer into which is to be written the number of wide characters read
from the input stream so far by this call to the fwscanf function. Execution
of a %n directive does not increment the assignment count returned at the
completion of execution of the fwscanf function. No argument is
converted, but one is consumed. If the conversion specification includes an
assignment-suppressing wide character or a field width, the behavior is
- undefined.</pre>
- % Matches a single % wide character; no conversion or assignment occurs. The
+ undefined.
+<dt> % <dd> Matches a single % wide character; no conversion or assignment occurs. The
+ complete conversion specification shall be %%.
+</dl>
<p><!--para 13 -->
-<pre>
- complete conversion specification shall be %%.</pre>
If a conversion specification is invalid, the behavior is undefined.<sup><a href="#note290"><b>290)</b></a></sup>
<p><!--para 14 -->
The conversion specifiers A, E, F, G, and X are also valid and behave the same as,
<p><small><a name="note290" href="#note290">290)</a> See ''future library directions'' (<a href="#7.26.12">7.26.12</a>).
</small>
-<a name="7.24.2.3" href="#7.24.2.3"><h5>7.24.2.3 The swprintf function</h5></a>
+<h5><a name="7.24.2.3" href="#7.24.2.3">7.24.2.3 The swprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
counting the terminating null wide character, or a negative value if an encoding error
occurred or if n or more wide characters were requested to be written.
-<a name="7.24.2.4" href="#7.24.2.4"><h5>7.24.2.4 The swscanf function</h5></a>
+<h5><a name="7.24.2.4" href="#7.24.2.4">7.24.2.4 The swscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
early matching failure.
<!--page 375 -->
-<a name="7.24.2.5" href="#7.24.2.5"><h5>7.24.2.5 The vfwprintf function</h5></a>
+<h5><a name="7.24.2.5" href="#7.24.2.5">7.24.2.5 The vfwprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
invoke the va_arg macro, the value of arg after the return is indeterminate.
</small>
-<a name="7.24.2.6" href="#7.24.2.6"><h5>7.24.2.6 The vfwscanf function</h5></a>
+<h5><a name="7.24.2.6" href="#7.24.2.6">7.24.2.6 The vfwscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vfwscanf function is equivalent to fwscanf, with the variable argument list
replaced by arg, which shall have been initialized by the va_start macro (and
possibly subsequent va_arg calls). The vfwscanf function does not invoke the
- va_end macro.291)
+ va_end macro.<sup><a href="#note291"><b>291)</b></a></sup>
<h6>Returns</h6>
<p><!--para 3 -->
The vfwscanf function returns the value of the macro EOF if an input failure occurs
items assigned, which can be fewer than provided for, or even zero, in the event of an
early matching failure.
-<a name="7.24.2.7" href="#7.24.2.7"><h5>7.24.2.7 The vswprintf function</h5></a>
+<h5><a name="7.24.2.7" href="#7.24.2.7">7.24.2.7 The vswprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vswprintf function is equivalent to swprintf, with the variable argument list
replaced by arg, which shall have been initialized by the va_start macro (and
possibly subsequent va_arg calls). The vswprintf function does not invoke the
- va_end macro.291)
+ va_end macro.<sup><a href="#note291"><b>291)</b></a></sup>
<h6>Returns</h6>
<p><!--para 3 -->
The vswprintf function returns the number of wide characters written in the array, not
occurred or if n or more wide characters were requested to be generated.
<!--page 377 -->
-<a name="7.24.2.8" href="#7.24.2.8"><h5>7.24.2.8 The vswscanf function</h5></a>
+<h5><a name="7.24.2.8" href="#7.24.2.8">7.24.2.8 The vswscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vswscanf function is equivalent to swscanf, with the variable argument list
replaced by arg, which shall have been initialized by the va_start macro (and
possibly subsequent va_arg calls). The vswscanf function does not invoke the
- va_end macro.291)
+ va_end macro.<sup><a href="#note291"><b>291)</b></a></sup>
<h6>Returns</h6>
<p><!--para 3 -->
The vswscanf function returns the value of the macro EOF if an input failure occurs
items assigned, which can be fewer than provided for, or even zero, in the event of an
early matching failure.
-<a name="7.24.2.9" href="#7.24.2.9"><h5>7.24.2.9 The vwprintf function</h5></a>
+<h5><a name="7.24.2.9" href="#7.24.2.9">7.24.2.9 The vwprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vwprintf function is equivalent to wprintf, with the variable argument list
replaced by arg, which shall have been initialized by the va_start macro (and
possibly subsequent va_arg calls). The vwprintf function does not invoke the
- va_end macro.291)
+ va_end macro.<sup><a href="#note291"><b>291)</b></a></sup>
<h6>Returns</h6>
<p><!--para 3 -->
The vwprintf function returns the number of wide characters transmitted, or a negative
value if an output or encoding error occurred.
<!--page 378 -->
-<a name="7.24.2.10" href="#7.24.2.10"><h5>7.24.2.10 The vwscanf function</h5></a>
+<h5><a name="7.24.2.10" href="#7.24.2.10">7.24.2.10 The vwscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The vwscanf function is equivalent to wscanf, with the variable argument list
replaced by arg, which shall have been initialized by the va_start macro (and
possibly subsequent va_arg calls). The vwscanf function does not invoke the
- va_end macro.291)
+ va_end macro.<sup><a href="#note291"><b>291)</b></a></sup>
<h6>Returns</h6>
<p><!--para 3 -->
The vwscanf function returns the value of the macro EOF if an input failure occurs
items assigned, which can be fewer than provided for, or even zero, in the event of an
early matching failure.
-<a name="7.24.2.11" href="#7.24.2.11"><h5>7.24.2.11 The wprintf function</h5></a>
+<h5><a name="7.24.2.11" href="#7.24.2.11">7.24.2.11 The wprintf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The wprintf function returns the number of wide characters transmitted, or a negative
value if an output or encoding error occurred.
-<a name="7.24.2.12" href="#7.24.2.12"><h5>7.24.2.12 The wscanf function</h5></a>
+<h5><a name="7.24.2.12" href="#7.24.2.12">7.24.2.12 The wscanf function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
items assigned, which can be fewer than provided for, or even zero, in the event of an
early matching failure.
-<a name="7.24.3" href="#7.24.3"><h4>7.24.3 Wide character input/output functions</h4></a>
+<h4><a name="7.24.3" href="#7.24.3">7.24.3 Wide character input/output functions</a></h4>
-<a name="7.24.3.1" href="#7.24.3.1"><h5>7.24.3.1 The fgetwc function</h5></a>
+<h5><a name="7.24.3.1" href="#7.24.3.1">7.24.3.1 The fgetwc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
Also, errno will be set to EILSEQ by input/output functions only if an encoding error occurs.
</small>
-<a name="7.24.3.2" href="#7.24.3.2"><h5>7.24.3.2 The fgetws function</h5></a>
+<h5><a name="7.24.3.2" href="#7.24.3.2">7.24.3.2 The fgetws function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
null pointer is returned. If a read or encoding error occurs during the operation, the array
contents are indeterminate and a null pointer is returned.
-<a name="7.24.3.3" href="#7.24.3.3"><h5>7.24.3.3 The fputwc function</h5></a>
+<h5><a name="7.24.3.3" href="#7.24.3.3">7.24.3.3 The fputwc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
error indicator for the stream is set and fputwc returns WEOF. If an encoding error
occurs, the value of the macro EILSEQ is stored in errno and fputwc returns WEOF.
-<a name="7.24.3.4" href="#7.24.3.4"><h5>7.24.3.4 The fputws function</h5></a>
+<h5><a name="7.24.3.4" href="#7.24.3.4">7.24.3.4 The fputws function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
returns a nonnegative value.
<!--page 381 -->
-<a name="7.24.3.5" href="#7.24.3.5"><h5>7.24.3.5 The fwide function</h5></a>
+<h5><a name="7.24.3.5" href="#7.24.3.5">7.24.3.5 The fwide function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note293" href="#note293">293)</a> If the orientation of the stream has already been determined, fwide does not change it.
</small>
-<a name="7.24.3.6" href="#7.24.3.6"><h5>7.24.3.6 The getwc function</h5></a>
+<h5><a name="7.24.3.6" href="#7.24.3.6">7.24.3.6 The getwc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The getwc function returns the next wide character from the input stream pointed to by
stream, or WEOF.
-<a name="7.24.3.7" href="#7.24.3.7"><h5>7.24.3.7 The getwchar function</h5></a>
+<h5><a name="7.24.3.7" href="#7.24.3.7">7.24.3.7 The getwchar function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The getwchar function returns the next wide character from the input stream pointed to
by stdin, or WEOF.
-<a name="7.24.3.8" href="#7.24.3.8"><h5>7.24.3.8 The putwc function</h5></a>
+<h5><a name="7.24.3.8" href="#7.24.3.8">7.24.3.8 The putwc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The putwc function returns the wide character written, or WEOF.
-<a name="7.24.3.9" href="#7.24.3.9"><h5>7.24.3.9 The putwchar function</h5></a>
+<h5><a name="7.24.3.9" href="#7.24.3.9">7.24.3.9 The putwchar function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The putwchar function returns the character written, or WEOF.
-<a name="7.24.3.10" href="#7.24.3.10"><h5>7.24.3.10 The ungetwc function</h5></a>
+<h5><a name="7.24.3.10" href="#7.24.3.10">7.24.3.10 The ungetwc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The ungetwc function returns the wide character pushed back, or WEOF if the operation
fails.
-<a name="7.24.4" href="#7.24.4"><h4>7.24.4 General wide string utilities</h4></a>
+<h4><a name="7.24.4" href="#7.24.4">7.24.4 General wide string utilities</a></h4>
<p><!--para 1 -->
The header <a href="#7.24"><wchar.h></a> declares a number of functions useful for wide string
manipulation. Various methods are used for determining the lengths of the arrays, but in
zero wide characters.
<!--page 384 -->
-<a name="7.24.4.1" href="#7.24.4.1"><h5>7.24.4.1 Wide string numeric conversion functions</h5></a>
+<h5><a name="7.24.4.1" href="#7.24.4.1">7.24.4.1 Wide string numeric conversion functions</a></h5>
-<a name="7.24.4.1.1" href="#7.24.4.1.1"><h5>7.24.4.1.1 The wcstod, wcstof, and wcstold functions</h5></a>
+<h5><a name="7.24.4.1.1" href="#7.24.4.1.1">7.24.4.1.1 The wcstod, wcstof, and wcstold functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
decimal-point wide character, then an optional binary exponent part as defined in
<a href="#6.4.4.2">6.4.4.2</a>;
<li> INF or INFINITY, or any other wide string equivalent except for case
-<li> NAN or NAN(n-wchar-sequenceopt), or any other wide string equivalent except for
+<li> NAN or NAN(n-wchar-sequence<sub>opt</sub>), or any other wide string equivalent except for
case in the NAN part, where:
<pre>
n-wchar-sequence:
sign, the sequence is interpreted as negated.<sup><a href="#note294"><b>294)</b></a></sup> A wide character sequence INF or
INFINITY is interpreted as an infinity, if representable in the return type, else like a
floating constant that is too large for the range of the return type. A wide character
- sequence NAN or NAN(n-wchar-sequenceopt) is interpreted as a quiet NaN, if supported
+ sequence NAN or NAN(n-wchar-sequence<sub>opt</sub>) is interpreted as a quiet NaN, if supported
in the return type, else like a subject sequence part that does not have the expected form;
the meaning of the n-wchar sequences is implementation-defined.<sup><a href="#note295"><b>295)</b></a></sup> A pointer to the
final wide string is stored in the object pointed to by endptr, provided that endptr is
If the subject sequence is empty or does not have the expected form, no conversion is
performed; the value of nptr is stored in the object pointed to by endptr, provided
that endptr is not a null pointer.
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 8 -->
If the subject sequence has the hexadecimal form, FLT_RADIX is not a power of 2, and
the result is not exactly representable, the result should be one of the two numbers in the
to the same internal floating value, but if not will round to adjacent values.
</small>
-<a name="7.24.4.1.2" href="#7.24.4.1.2"><h5>7.24.4.1.2 The wcstol, wcstoll, wcstoul, and wcstoull functions</h5></a>
+<h5><a name="7.24.4.1.2" href="#7.24.4.1.2">7.24.4.1.2 The wcstol, wcstoll, wcstoul, and wcstoull functions</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
LLONG_MAX, ULONG_MAX, or ULLONG_MAX is returned (according to the return type
sign of the value, if any), and the value of the macro ERANGE is stored in errno.
-<a name="7.24.4.2" href="#7.24.4.2"><h5>7.24.4.2 Wide string copying functions</h5></a>
+<h5><a name="7.24.4.2" href="#7.24.4.2">7.24.4.2 Wide string copying functions</a></h5>
-<a name="7.24.4.2.1" href="#7.24.4.2.1"><h5>7.24.4.2.1 The wcscpy function</h5></a>
+<h5><a name="7.24.4.2.1" href="#7.24.4.2.1">7.24.4.2.1 The wcscpy function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The wcscpy function returns the value of s1.
<!--page 389 -->
-<a name="7.24.4.2.2" href="#7.24.4.2.2"><h5>7.24.4.2.2 The wcsncpy function</h5></a>
+<h5><a name="7.24.4.2.2" href="#7.24.4.2.2">7.24.4.2.2 The wcsncpy function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
result will not be null-terminated.
</small>
-<a name="7.24.4.2.3" href="#7.24.4.2.3"><h5>7.24.4.2.3 The wmemcpy function</h5></a>
+<h5><a name="7.24.4.2.3" href="#7.24.4.2.3">7.24.4.2.3 The wmemcpy function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<!--page 390 -->
-<a name="7.24.4.2.4" href="#7.24.4.2.4"><h5>7.24.4.2.4 The wmemmove function</h5></a>
+<h5><a name="7.24.4.2.4" href="#7.24.4.2.4">7.24.4.2.4 The wmemmove function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The wmemmove function returns the value of s1.
-<a name="7.24.4.3" href="#7.24.4.3"><h5>7.24.4.3 Wide string concatenation functions</h5></a>
+<h5><a name="7.24.4.3" href="#7.24.4.3">7.24.4.3 Wide string concatenation functions</a></h5>
-<a name="7.24.4.3.1" href="#7.24.4.3.1"><h5>7.24.4.3.1 The wcscat function</h5></a>
+<h5><a name="7.24.4.3.1" href="#7.24.4.3.1">7.24.4.3.1 The wcscat function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The wcscat function returns the value of s1.
-<a name="7.24.4.3.2" href="#7.24.4.3.2"><h5>7.24.4.3.2 The wcsncat function</h5></a>
+<h5><a name="7.24.4.3.2" href="#7.24.4.3.2">7.24.4.3.2 The wcsncat function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
wcslen(s1)+n+1.
</small>
-<a name="7.24.4.4" href="#7.24.4.4"><h5>7.24.4.4 Wide string comparison functions</h5></a>
+<h5><a name="7.24.4.4" href="#7.24.4.4">7.24.4.4 Wide string comparison functions</a></h5>
<p><!--para 1 -->
Unless explicitly stated otherwise, the functions described in this subclause order two
wide characters the same way as two integers of the underlying integer type designated
by wchar_t.
-<a name="7.24.4.4.1" href="#7.24.4.4.1"><h5>7.24.4.4.1 The wcscmp function</h5></a>
+<h5><a name="7.24.4.4.1" href="#7.24.4.4.1">7.24.4.4.1 The wcscmp function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
accordingly as the wide string pointed to by s1 is greater than, equal to, or less than the
wide string pointed to by s2.
-<a name="7.24.4.4.2" href="#7.24.4.4.2"><h5>7.24.4.4.2 The wcscoll function</h5></a>
+<h5><a name="7.24.4.4.2" href="#7.24.4.4.2">7.24.4.4.2 The wcscoll function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
wide string pointed to by s2 when both are interpreted as appropriate to the current
locale.
-<a name="7.24.4.4.3" href="#7.24.4.4.3"><h5>7.24.4.4.3 The wcsncmp function</h5></a>
+<h5><a name="7.24.4.4.3" href="#7.24.4.4.3">7.24.4.4.3 The wcsncmp function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
accordingly as the possibly null-terminated array pointed to by s1 is greater than, equal
to, or less than the possibly null-terminated array pointed to by s2.
-<a name="7.24.4.4.4" href="#7.24.4.4.4"><h5>7.24.4.4.4 The wcsxfrm function</h5></a>
+<h5><a name="7.24.4.4.4" href="#7.24.4.4.4">7.24.4.4.4 The wcsxfrm function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
1 + wcsxfrm(NULL, s, 0)</pre>
-<a name="7.24.4.4.5" href="#7.24.4.4.5"><h5>7.24.4.4.5 The wmemcmp function</h5></a>
+<h5><a name="7.24.4.4.5" href="#7.24.4.4.5">7.24.4.4.5 The wmemcmp function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
accordingly as the object pointed to by s1 is greater than, equal to, or less than the object
pointed to by s2.
-<a name="7.24.4.5" href="#7.24.4.5"><h5>7.24.4.5 Wide string search functions</h5></a>
+<h5><a name="7.24.4.5" href="#7.24.4.5">7.24.4.5 Wide string search functions</a></h5>
-<a name="7.24.4.5.1" href="#7.24.4.5.1"><h5>7.24.4.5.1 The wcschr function</h5></a>
+<h5><a name="7.24.4.5.1" href="#7.24.4.5.1">7.24.4.5.1 The wcschr function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The wcschr function returns a pointer to the located wide character, or a null pointer if
the wide character does not occur in the wide string.
-<a name="7.24.4.5.2" href="#7.24.4.5.2"><h5>7.24.4.5.2 The wcscspn function</h5></a>
+<h5><a name="7.24.4.5.2" href="#7.24.4.5.2">7.24.4.5.2 The wcscspn function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The wcscspn function returns the length of the segment.
-<a name="7.24.4.5.3" href="#7.24.4.5.3"><h5>7.24.4.5.3 The wcspbrk function</h5></a>
+<h5><a name="7.24.4.5.3" href="#7.24.4.5.3">7.24.4.5.3 The wcspbrk function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The wcspbrk function returns a pointer to the wide character in s1, or a null pointer if
no wide character from s2 occurs in s1.
-<a name="7.24.4.5.4" href="#7.24.4.5.4"><h5>7.24.4.5.4 The wcsrchr function</h5></a>
+<h5><a name="7.24.4.5.4" href="#7.24.4.5.4">7.24.4.5.4 The wcsrchr function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The wcsrchr function returns a pointer to the wide character, or a null pointer if c does
not occur in the wide string.
-<a name="7.24.4.5.5" href="#7.24.4.5.5"><h5>7.24.4.5.5 The wcsspn function</h5></a>
+<h5><a name="7.24.4.5.5" href="#7.24.4.5.5">7.24.4.5.5 The wcsspn function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The wcsspn function returns the length of the segment.
<!--page 395 -->
-<a name="7.24.4.5.6" href="#7.24.4.5.6"><h5>7.24.4.5.6 The wcsstr function</h5></a>
+<h5><a name="7.24.4.5.6" href="#7.24.4.5.6">7.24.4.5.6 The wcsstr function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
wide string is not found. If s2 points to a wide string with zero length, the function
returns s1.
-<a name="7.24.4.5.7" href="#7.24.4.5.7"><h5>7.24.4.5.7 The wcstok function</h5></a>
+<h5><a name="7.24.4.5.7" href="#7.24.4.5.7">7.24.4.5.7 The wcstok function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
t = wcstok(NULL, L"?", &ptr1); // t is a null pointer</pre>
-<a name="7.24.4.5.8" href="#7.24.4.5.8"><h5>7.24.4.5.8 The wmemchr function</h5></a>
+<h5><a name="7.24.4.5.8" href="#7.24.4.5.8">7.24.4.5.8 The wmemchr function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
the wide character does not occur in the object.
<!--page 397 -->
-<a name="7.24.4.6" href="#7.24.4.6"><h5>7.24.4.6 Miscellaneous functions</h5></a>
+<h5><a name="7.24.4.6" href="#7.24.4.6">7.24.4.6 Miscellaneous functions</a></h5>
-<a name="7.24.4.6.1" href="#7.24.4.6.1"><h5>7.24.4.6.1 The wcslen function</h5></a>
+<h5><a name="7.24.4.6.1" href="#7.24.4.6.1">7.24.4.6.1 The wcslen function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The wcslen function returns the number of wide characters that precede the terminating
null wide character.
-<a name="7.24.4.6.2" href="#7.24.4.6.2"><h5>7.24.4.6.2 The wmemset function</h5></a>
+<h5><a name="7.24.4.6.2" href="#7.24.4.6.2">7.24.4.6.2 The wmemset function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 3 -->
The wmemset function returns the value of s.
-<a name="7.24.5" href="#7.24.5"><h4>7.24.5 Wide character time conversion functions</h4></a>
+<h4><a name="7.24.5" href="#7.24.5">7.24.5 Wide character time conversion functions</a></h4>
-<a name="7.24.5.1" href="#7.24.5.1"><h5>7.24.5.1 The wcsftime function</h5></a>
+<h5><a name="7.24.5.1" href="#7.24.5.1">7.24.5.1 The wcsftime function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
wide character. Otherwise, zero is returned and the contents of the array are
indeterminate.
-<a name="7.24.6" href="#7.24.6"><h4>7.24.6 Extended multibyte/wide character conversion utilities</h4></a>
+<h4><a name="7.24.6" href="#7.24.6">7.24.6 Extended multibyte/wide character conversion utilities</a></h4>
<p><!--para 1 -->
The header <a href="#7.24"><wchar.h></a> declares an extended set of functions useful for conversion
between multibyte characters and wide characters.
character string.
</small>
-<a name="7.24.6.1" href="#7.24.6.1"><h5>7.24.6.1 Single-byte/wide character conversion functions</h5></a>
+<h5><a name="7.24.6.1" href="#7.24.6.1">7.24.6.1 Single-byte/wide character conversion functions</a></h5>
-<a name="7.24.6.1.1" href="#7.24.6.1.1"><h5>7.24.6.1.1 The btowc function</h5></a>
+<h5><a name="7.24.6.1.1" href="#7.24.6.1.1">7.24.6.1.1 The btowc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
does not constitute a valid single-byte character in the initial shift state. Otherwise, it
returns the wide character representation of that character.
-<a name="7.24.6.1.2" href="#7.24.6.1.2"><h5>7.24.6.1.2 The wctob function</h5></a>
+<h5><a name="7.24.6.1.2" href="#7.24.6.1.2">7.24.6.1.2 The wctob function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
length one in the initial shift state. Otherwise, it returns the single-byte representation of
that character as an unsigned char converted to an int.
-<a name="7.24.6.2" href="#7.24.6.2"><h5>7.24.6.2 Conversion state functions</h5></a>
+<h5><a name="7.24.6.2" href="#7.24.6.2">7.24.6.2 Conversion state functions</a></h5>
-<a name="7.24.6.2.1" href="#7.24.6.2.1"><h5>7.24.6.2.1 The mbsinit function</h5></a>
+<h5><a name="7.24.6.2.1" href="#7.24.6.2.1">7.24.6.2.1 The mbsinit function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The mbsinit function returns nonzero if ps is a null pointer or if the pointed-to object
describes an initial conversion state; otherwise, it returns zero.
-<a name="7.24.6.3" href="#7.24.6.3"><h5>7.24.6.3 Restartable multibyte/wide character conversion functions</h5></a>
+<h5><a name="7.24.6.3" href="#7.24.6.3">7.24.6.3 Restartable multibyte/wide character conversion functions</a></h5>
<p><!--para 1 -->
These functions differ from the corresponding multibyte character functions of <a href="#7.20.7">7.20.7</a>
(mblen, mbtowc, and wctomb) in that they have an extra parameter, ps, of type
Also unlike their corresponding functions, the return value does not represent whether the
encoding is state-dependent.
-<a name="7.24.6.3.1" href="#7.24.6.3.1"><h5>7.24.6.3.1 The mbrlen function</h5></a>
+<h5><a name="7.24.6.3.1" href="#7.24.6.3.1">7.24.6.3.1 The mbrlen function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><b> Forward references</b>: the mbrtowc function (<a href="#7.24.6.3.2">7.24.6.3.2</a>).
<!--page 401 -->
-<a name="7.24.6.3.2" href="#7.24.6.3.2"><h5>7.24.6.3.2 The mbrtowc function</h5></a>
+<h5><a name="7.24.6.3.2" href="#7.24.6.3.2">7.24.6.3.2 The mbrtowc function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 4 -->
The mbrtowc function returns the first of the following that applies (given the current
conversion state):
- 0 if the next n or fewer bytes complete the multibyte character that
-<pre>
- corresponds to the null wide character (which is the value stored).</pre>
- between 1 and n inclusive if the next n or fewer bytes complete a valid multibyte
-<pre>
+<dl>
+<dt> 0 <dd> if the next n or fewer bytes complete the multibyte character that
+ corresponds to the null wide character (which is the value stored).
+<dt> between 1 and n inclusive<dd> if the next n or fewer bytes complete a valid multibyte
character (which is the value stored); the value returned is the number
- of bytes that complete the multibyte character.</pre>
- (size_t)(-2) if the next n bytes contribute to an incomplete (but potentially valid)
-<pre>
+ of bytes that complete the multibyte character.
+<dt> (size_t)(-2)<dd> if the next n bytes contribute to an incomplete (but potentially valid)
multibyte character, and all n bytes have been processed (no value is
- stored).<sup><a href="#note300"><b>300)</b></a></sup></pre>
- (size_t)(-1) if an encoding error occurs, in which case the next n or fewer bytes
-<pre>
+ stored).<sup><a href="#note300"><b>300)</b></a></sup>
+<dt> (size_t)(-1)<dd> if an encoding error occurs, in which case the next n or fewer bytes
do not contribute to a complete and valid multibyte character (no
value is stored); the value of the macro EILSEQ is stored in errno,
- and the conversion state is unspecified.</pre>
-
+ and the conversion state is unspecified.
+</dl>
<!--page 402 -->
<h6>footnotes</h6>
sequence of redundant shift sequences (for implementations with state-dependent encodings).
</small>
-<a name="7.24.6.3.3" href="#7.24.6.3.3"><h5>7.24.6.3.3 The wcrtomb function</h5></a>
+<h5><a name="7.24.6.3.3" href="#7.24.6.3.3">7.24.6.3.3 The wcrtomb function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
the function stores the value of the macro EILSEQ in errno and returns
(size_t)(-1); the conversion state is unspecified.
-<a name="7.24.6.4" href="#7.24.6.4"><h5>7.24.6.4 Restartable multibyte/wide string conversion functions</h5></a>
+<h5><a name="7.24.6.4" href="#7.24.6.4">7.24.6.4 Restartable multibyte/wide string conversion functions</a></h5>
<p><!--para 1 -->
These functions differ from the corresponding multibyte string functions of <a href="#7.20.8">7.20.8</a>
(mbstowcs and wcstombs) in that they have an extra parameter, ps, of type pointer to
to reflect the amount of the source processed by that invocation.
<!--page 403 -->
-<a name="7.24.6.4.1" href="#7.24.6.4.1"><h5>7.24.6.4.1 The mbsrtowcs function</h5></a>
+<h5><a name="7.24.6.4.1" href="#7.24.6.4.1">7.24.6.4.1 The mbsrtowcs function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><small><a name="note301" href="#note301">301)</a> Thus, the value of len is ignored if dst is a null pointer.
</small>
-<a name="7.24.6.4.2" href="#7.24.6.4.2"><h5>7.24.6.4.2 The wcsrtombs function</h5></a>
+<h5><a name="7.24.6.4.2" href="#7.24.6.4.2">7.24.6.4.2 The wcsrtombs function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
include those necessary to reach the initial shift state immediately before the null byte.
</small>
-<a name="7.25" href="#7.25"><h3>7.25 Wide character classification and mapping utilities <wctype.h></h3></a>
+<h3><a name="7.25" href="#7.25">7.25 Wide character classification and mapping utilities <wctype.h></a></h3>
-<a name="7.25.1" href="#7.25.1"><h4>7.25.1 Introduction</h4></a>
+<h4><a name="7.25.1" href="#7.25.1">7.25.1 Introduction</a></h4>
<p><!--para 1 -->
The header <a href="#7.25"><wctype.h></a> declares three data types, one macro, and many functions.<sup><a href="#note303"><b>303)</b></a></sup>
<p><!--para 2 -->
<p><small><a name="note303" href="#note303">303)</a> See ''future library directions'' (<a href="#7.26.13">7.26.13</a>).
</small>
-<a name="7.25.2" href="#7.25.2"><h4>7.25.2 Wide character classification utilities</h4></a>
+<h4><a name="7.25.2" href="#7.25.2">7.25.2 Wide character classification utilities</a></h4>
<p><!--para 1 -->
The header <a href="#7.25"><wctype.h></a> declares several functions useful for classifying wide
characters.
term control wide character refers to a member of a locale-specific set of wide characters
that are not printing wide characters.
-<a name="7.25.2.1" href="#7.25.2.1"><h5>7.25.2.1 Wide character classification functions</h5></a>
+<h5><a name="7.25.2.1" href="#7.25.2.1">7.25.2.1 Wide character classification functions</a></h5>
<p><!--para 1 -->
The functions in this subclause return nonzero (true) if and only if the value of the
argument wc conforms to that in the description of the function.
&& iswspace(wc) is true, but not both.
</small>
-<a name="7.25.2.1.1" href="#7.25.2.1.1"><h5>7.25.2.1.1 The iswalnum function</h5></a>
+<h5><a name="7.25.2.1.1" href="#7.25.2.1.1">7.25.2.1.1 The iswalnum function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The iswalnum function tests for any wide character for which iswalpha or
iswdigit is true.
-<a name="7.25.2.1.2" href="#7.25.2.1.2"><h5>7.25.2.1.2 The iswalpha function</h5></a>
+<h5><a name="7.25.2.1.2" href="#7.25.2.1.2">7.25.2.1.2 The iswalpha function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
wide characters; all four combinations are possible.
</small>
-<a name="7.25.2.1.3" href="#7.25.2.1.3"><h5>7.25.2.1.3 The iswblank function</h5></a>
+<h5><a name="7.25.2.1.3" href="#7.25.2.1.3">7.25.2.1.3 The iswblank function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
characters are the following: space (L' '), and horizontal tab (L'\t'). In the "C"
locale, iswblank returns true only for the standard blank characters.
-<a name="7.25.2.1.4" href="#7.25.2.1.4"><h5>7.25.2.1.4 The iswcntrl function</h5></a>
+<h5><a name="7.25.2.1.4" href="#7.25.2.1.4">7.25.2.1.4 The iswcntrl function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The iswcntrl function tests for any control wide character.
-<a name="7.25.2.1.5" href="#7.25.2.1.5"><h5>7.25.2.1.5 The iswdigit function</h5></a>
+<h5><a name="7.25.2.1.5" href="#7.25.2.1.5">7.25.2.1.5 The iswdigit function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The iswdigit function tests for any wide character that corresponds to a decimal-digit
character (as defined in <a href="#5.2.1">5.2.1</a>).
-<a name="7.25.2.1.6" href="#7.25.2.1.6"><h5>7.25.2.1.6 The iswgraph function</h5></a>
+<h5><a name="7.25.2.1.6" href="#7.25.2.1.6">7.25.2.1.6 The iswgraph function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
characters other than ' '.
</small>
-<a name="7.25.2.1.7" href="#7.25.2.1.7"><h5>7.25.2.1.7 The iswlower function</h5></a>
+<h5><a name="7.25.2.1.7" href="#7.25.2.1.7">7.25.2.1.7 The iswlower function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
letter or is one of a locale-specific set of wide characters for which none of iswcntrl,
iswdigit, iswpunct, or iswspace is true.
-<a name="7.25.2.1.8" href="#7.25.2.1.8"><h5>7.25.2.1.8 The iswprint function</h5></a>
+<h5><a name="7.25.2.1.8" href="#7.25.2.1.8">7.25.2.1.8 The iswprint function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
<p><!--para 2 -->
The iswprint function tests for any printing wide character.
-<a name="7.25.2.1.9" href="#7.25.2.1.9"><h5>7.25.2.1.9 The iswpunct function</h5></a>
+<h5><a name="7.25.2.1.9" href="#7.25.2.1.9">7.25.2.1.9 The iswpunct function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
specific set of punctuation wide characters for which neither iswspace nor iswalnum
is true.306)
-<a name="7.25.2.1.10" href="#7.25.2.1.10"><h5>7.25.2.1.10 The iswspace function</h5></a>
+<h5><a name="7.25.2.1.10" href="#7.25.2.1.10">7.25.2.1.10 The iswspace function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
set of white-space wide characters for which none of iswalnum, iswgraph, or
iswpunct is true.
-<a name="7.25.2.1.11" href="#7.25.2.1.11"><h5>7.25.2.1.11 The iswupper function</h5></a>
+<h5><a name="7.25.2.1.11" href="#7.25.2.1.11">7.25.2.1.11 The iswupper function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
letter or is one of a locale-specific set of wide characters for which none of iswcntrl,
iswdigit, iswpunct, or iswspace is true.
-<a name="7.25.2.1.12" href="#7.25.2.1.12"><h5>7.25.2.1.12 The iswxdigit function</h5></a>
+<h5><a name="7.25.2.1.12" href="#7.25.2.1.12">7.25.2.1.12 The iswxdigit function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The iswxdigit function tests for any wide character that corresponds to a
hexadecimal-digit character (as defined in <a href="#6.4.4.1">6.4.4.1</a>).
-<a name="7.25.2.2" href="#7.25.2.2"><h5>7.25.2.2 Extensible wide character classification functions</h5></a>
+<h5><a name="7.25.2.2" href="#7.25.2.2">7.25.2.2 Extensible wide character classification functions</a></h5>
<p><!--para 1 -->
The functions wctype and iswctype provide extensible wide character classification
as well as testing equivalent to that performed by the functions described in the previous
subclause (<a href="#7.25.2.1">7.25.2.1</a>).
-<a name="7.25.2.2.1" href="#7.25.2.2.1"><h5>7.25.2.2.1 The iswctype function</h5></a>
+<h5><a name="7.25.2.2.1" href="#7.25.2.2.1">7.25.2.2.1 The iswctype function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
character wc has the property described by desc.
<p><b> Forward references</b>: the wctype function (<a href="#7.25.2.2.2">7.25.2.2.2</a>).
-<a name="7.25.2.2.2" href="#7.25.2.2.2"><h5>7.25.2.2.2 The wctype function</h5></a>
+<h5><a name="7.25.2.2.2" href="#7.25.2.2.2">7.25.2.2.2 The wctype function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
as the second argument to the iswctype function; otherwise, it returns zero. *
<!--page 411 -->
-<a name="7.25.3" href="#7.25.3"><h4>7.25.3 Wide character case mapping utilities</h4></a>
+<h4><a name="7.25.3" href="#7.25.3">7.25.3 Wide character case mapping utilities</a></h4>
<p><!--para 1 -->
The header <a href="#7.25"><wctype.h></a> declares several functions useful for mapping wide characters.
-<a name="7.25.3.1" href="#7.25.3.1"><h5>7.25.3.1 Wide character case mapping functions</h5></a>
+<h5><a name="7.25.3.1" href="#7.25.3.1">7.25.3.1 Wide character case mapping functions</a></h5>
-<a name="7.25.3.1.1" href="#7.25.3.1.1"><h5>7.25.3.1.1 The towlower function</h5></a>
+<h5><a name="7.25.3.1.1" href="#7.25.3.1.1">7.25.3.1.1 The towlower function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
characters (always the same one for any given locale); otherwise, the argument is
returned unchanged.
-<a name="7.25.3.1.2" href="#7.25.3.1.2"><h5>7.25.3.1.2 The towupper function</h5></a>
+<h5><a name="7.25.3.1.2" href="#7.25.3.1.2">7.25.3.1.2 The towupper function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
characters (always the same one for any given locale); otherwise, the argument is
returned unchanged.
-<a name="7.25.3.2" href="#7.25.3.2"><h5>7.25.3.2 Extensible wide character case mapping functions</h5></a>
+<h5><a name="7.25.3.2" href="#7.25.3.2">7.25.3.2 Extensible wide character case mapping functions</a></h5>
<p><!--para 1 -->
The functions wctrans and towctrans provide extensible wide character mapping as
well as case mapping equivalent to that performed by the functions described in the
previous subclause (<a href="#7.25.3.1">7.25.3.1</a>).
<!--page 412 -->
-<a name="7.25.3.2.1" href="#7.25.3.2.1"><h5>7.25.3.2.1 The towctrans function</h5></a>
+<h5><a name="7.25.3.2.1" href="#7.25.3.2.1">7.25.3.2.1 The towctrans function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
The towctrans function returns the mapped value of wc using the mapping described
by desc.
-<a name="7.25.3.2.2" href="#7.25.3.2.2"><h5>7.25.3.2.2 The wctrans function</h5></a>
+<h5><a name="7.25.3.2.2" href="#7.25.3.2.2">7.25.3.2.2 The wctrans function</a></h5>
<h6>Synopsis</h6>
<p><!--para 1 -->
<pre>
as the second argument to the towctrans function; otherwise, it returns zero.
<!--page 413 -->
-<a name="7.26" href="#7.26"><h3>7.26 Future library directions</h3></a>
+<h3><a name="7.26" href="#7.26">7.26 Future library directions</a></h3>
<p><!--para 1 -->
The following names are grouped under individual headers for convenience. All external
names described below are reserved no matter what headers are included by the program.
-<a name="7.26.1" href="#7.26.1"><h4>7.26.1 Complex arithmetic <complex.h></h4></a>
+<h4><a name="7.26.1" href="#7.26.1">7.26.1 Complex arithmetic <complex.h></a></h4>
<p><!--para 1 -->
The function names
<pre>
and the same names suffixed with f or l may be added to the declarations in the
<a href="#7.3"><complex.h></a> header.
-<a name="7.26.2" href="#7.26.2"><h4>7.26.2 Character handling <ctype.h></h4></a>
+<h4><a name="7.26.2" href="#7.26.2">7.26.2 Character handling <ctype.h></a></h4>
<p><!--para 1 -->
Function names that begin with either is or to, and a lowercase letter may be added to
the declarations in the <a href="#7.4"><ctype.h></a> header.
-<a name="7.26.3" href="#7.26.3"><h4>7.26.3 Errors <errno.h></h4></a>
+<h4><a name="7.26.3" href="#7.26.3">7.26.3 Errors <errno.h></a></h4>
<p><!--para 1 -->
Macros that begin with E and a digit or E and an uppercase letter may be added to the
declarations in the <a href="#7.5"><errno.h></a> header.
-<a name="7.26.4" href="#7.26.4"><h4>7.26.4 Format conversion of integer types <inttypes.h></h4></a>
+<h4><a name="7.26.4" href="#7.26.4">7.26.4 Format conversion of integer types <inttypes.h></a></h4>
<p><!--para 1 -->
Macro names beginning with PRI or SCN followed by any lowercase letter or X may be
added to the macros defined in the <a href="#7.8"><inttypes.h></a> header.
-<a name="7.26.5" href="#7.26.5"><h4>7.26.5 Localization <locale.h></h4></a>
+<h4><a name="7.26.5" href="#7.26.5">7.26.5 Localization <locale.h></a></h4>
<p><!--para 1 -->
Macros that begin with LC_ and an uppercase letter may be added to the definitions in
the <a href="#7.11"><locale.h></a> header.
-<a name="7.26.6" href="#7.26.6"><h4>7.26.6 Signal handling <signal.h></h4></a>
+<h4><a name="7.26.6" href="#7.26.6">7.26.6 Signal handling <signal.h></a></h4>
<p><!--para 1 -->
Macros that begin with either SIG and an uppercase letter or SIG_ and an uppercase
letter may be added to the definitions in the <a href="#7.14"><signal.h></a> header.
-<a name="7.26.7" href="#7.26.7"><h4>7.26.7 Boolean type and values <stdbool.h></h4></a>
+<h4><a name="7.26.7" href="#7.26.7">7.26.7 Boolean type and values <stdbool.h></a></h4>
<p><!--para 1 -->
The ability to undefine and perhaps then redefine the macros bool, true, and false is
an obsolescent feature.
-<a name="7.26.8" href="#7.26.8"><h4>7.26.8 Integer types <stdint.h></h4></a>
+<h4><a name="7.26.8" href="#7.26.8">7.26.8 Integer types <stdint.h></a></h4>
<p><!--para 1 -->
Typedef names beginning with int or uint and ending with _t may be added to the
types defined in the <a href="#7.18"><stdint.h></a> header. Macro names beginning with INT or UINT
<a href="#7.18"><stdint.h></a> header.
<!--page 414 -->
-<a name="7.26.9" href="#7.26.9"><h4>7.26.9 Input/output <stdio.h></h4></a>
+<h4><a name="7.26.9" href="#7.26.9">7.26.9 Input/output <stdio.h></a></h4>
<p><!--para 1 -->
Lowercase letters may be added to the conversion specifiers and length modifiers in
fprintf and fscanf. Other characters may be used in extensions.
The use of ungetc on a binary stream where the file position indicator is zero prior to
the call is an obsolescent feature.
-<a name="7.26.10" href="#7.26.10"><h4>7.26.10 General utilities <stdlib.h></h4></a>
+<h4><a name="7.26.10" href="#7.26.10">7.26.10 General utilities <stdlib.h></a></h4>
<p><!--para 1 -->
Function names that begin with str and a lowercase letter may be added to the
declarations in the <a href="#7.20"><stdlib.h></a> header.
-<a name="7.26.11" href="#7.26.11"><h4>7.26.11 String handling <string.h></h4></a>
+<h4><a name="7.26.11" href="#7.26.11">7.26.11 String handling <string.h></a></h4>
<p><!--para 1 -->
Function names that begin with str, mem, or wcs and a lowercase letter may be added
to the declarations in the <a href="#7.21"><string.h></a> header.
-<a name="7.26.12" href="#7.26.12"><h4>7.26.12 Extended multibyte and wide character utilities <wchar.h></h4></a>
+<h4><a name="7.26.12" href="#7.26.12">7.26.12 Extended multibyte and wide character utilities <wchar.h></a></h4>
<p><!--para 1 -->
Function names that begin with wcs and a lowercase letter may be added to the
declarations in the <a href="#7.24"><wchar.h></a> header.
Lowercase letters may be added to the conversion specifiers and length modifiers in
fwprintf and fwscanf. Other characters may be used in extensions.
-<a name="7.26.13" href="#7.26.13"><h4>7.26.13 Wide character classification and mapping utilities</h4></a>
+<h4><a name="7.26.13" href="#7.26.13">7.26.13 Wide character classification and mapping utilities</a></h4>
<a href="#7.25"><wctype.h></a>
<p><!--para 1 -->
Function names that begin with is or to and a lowercase letter may be added to the
declarations in the <a href="#7.25"><wctype.h></a> header.
<!--page 415 -->
-<a name="A" href="#A"><h2>Annex A</h2></a>
+<h2><a name="A" href="#A">Annex A</a></h2>
<p><!--para 1 -->
<pre>
(informative)
NOTE The notation is described in <a href="#6.1">6.1</a>.
-<a name="A.1" href="#A.1"><h3>A.1 Lexical grammar</h3></a>
+<h3><a name="A.1" href="#A.1">A.1 Lexical grammar</a></h3>
-<a name="A.1.1" href="#A.1.1"><h4>A.1.1 Lexical elements</h4></a>
+<h4><a name="A.1.1" href="#A.1.1">A.1.1 Lexical elements</a></h4>
(<a href="#6.4">6.4</a>) token:
<pre>
keyword
punctuator
each non-white-space character that cannot be one of the above</pre>
-<a name="A.1.2" href="#A.1.2"><h4>A.1.2 Keywords</h4></a>
+<h4><a name="A.1.2" href="#A.1.2">A.1.2 Keywords</a></h4>
(<a href="#6.4.1">6.4.1</a>) keyword: one of
<!--page 416 -->
<pre>
double long typedef
else register union</pre>
-<a name="A.1.3" href="#A.1.3"><h4>A.1.3 Identifiers</h4></a>
+<h4><a name="A.1.3" href="#A.1.3">A.1.3 Identifiers</a></h4>
(<a href="#6.4.2.1">6.4.2.1</a>) identifier:
<pre>
identifier-nondigit
<pre>
0 1 2 3 4 5 6 7 8 9</pre>
-<a name="A.1.4" href="#A.1.4"><h4>A.1.4 Universal character names</h4></a>
+<h4><a name="A.1.4" href="#A.1.4">A.1.4 Universal character names</a></h4>
(<a href="#6.4.3">6.4.3</a>) universal-character-name:
<pre>
\u hex-quad
hexadecimal-digit hexadecimal-digit
hexadecimal-digit hexadecimal-digit</pre>
-<a name="A.1.5" href="#A.1.5"><h4>A.1.5 Constants</h4></a>
+<h4><a name="A.1.5" href="#A.1.5">A.1.5 Constants</a></h4>
(<a href="#6.4.4">6.4.4</a>) constant:
<pre>
integer-constant
\x hexadecimal-digit
hexadecimal-escape-sequence hexadecimal-digit</pre>
-<a name="A.1.6" href="#A.1.6"><h4>A.1.6 String literals</h4></a>
+<h4><a name="A.1.6" href="#A.1.6">A.1.6 String literals</a></h4>
(<a href="#6.4.5">6.4.5</a>) string-literal:
<pre>
" s-char-sequenceopt "
the double-quote ", backslash \, or new-line character
escape-sequence</pre>
-<a name="A.1.7" href="#A.1.7"><h4>A.1.7 Punctuators</h4></a>
+<h4><a name="A.1.7" href="#A.1.7">A.1.7 Punctuators</a></h4>
(<a href="#6.4.6">6.4.6</a>) punctuator: one of
<pre>
[ ] ( ) { } . ->
, # ##
<: :> <% %> %: %:%:</pre>
-<a name="A.1.8" href="#A.1.8"><h4>A.1.8 Header names</h4></a>
+<h4><a name="A.1.8" href="#A.1.8">A.1.8 Header names</a></h4>
(<a href="#6.4.7">6.4.7</a>) header-name:
<pre>
< h-char-sequence >
any member of the source character set except
the new-line character and "</pre>
-<a name="A.1.9" href="#A.1.9"><h4>A.1.9 Preprocessing numbers</h4></a>
+<h4><a name="A.1.9" href="#A.1.9">A.1.9 Preprocessing numbers</a></h4>
(<a href="#6.4.8">6.4.8</a>) pp-number:
<!--page 421 -->
<pre>
pp-number P sign
pp-number .</pre>
-<a name="A.2" href="#A.2"><h3>A.2 Phrase structure grammar</h3></a>
+<h3><a name="A.2" href="#A.2">A.2 Phrase structure grammar</a></h3>
-<a name="A.2.1" href="#A.2.1"><h4>A.2.1 Expressions</h4></a>
+<h4><a name="A.2.1" href="#A.2.1">A.2.1 Expressions</a></h4>
(<a href="#6.5.1">6.5.1</a>) primary-expression:
<pre>
identifier
<pre>
conditional-expression</pre>
-<a name="A.2.2" href="#A.2.2"><h4>A.2.2 Declarations</h4></a>
+<h4><a name="A.2.2" href="#A.2.2">A.2.2 Declarations</a></h4>
(<a href="#6.7">6.7</a>) declaration:
<pre>
declaration-specifiers init-declarator-listopt ;</pre>
[ constant-expression ]
. identifier</pre>
-<a name="A.2.3" href="#A.2.3"><h4>A.2.3 Statements</h4></a>
+<h4><a name="A.2.3" href="#A.2.3">A.2.3 Statements</a></h4>
(<a href="#6.8">6.8</a>) statement:
<pre>
labeled-statement
break ;
return expressionopt ;</pre>
-<a name="A.2.4" href="#A.2.4"><h4>A.2.4 External definitions</h4></a>
+<h4><a name="A.2.4" href="#A.2.4">A.2.4 External definitions</a></h4>
(<a href="#6.9">6.9</a>) translation-unit:
<pre>
external-declaration
declaration
declaration-list declaration</pre>
-<a name="A.3" href="#A.3"><h3>A.3 Preprocessing directives</h3></a>
+<h3><a name="A.3" href="#A.3">A.3 Preprocessing directives</a></h3>
(<a href="#6.10">6.10</a>) preprocessing-file:
<pre>
groupopt</pre>
<pre>
the new-line character</pre>
-<a name="B" href="#B"><h2>Annex B</h2></a>
+<h2><a name="B" href="#B">Annex B</a></h2>
<pre>
(informative)
Library summary</pre>
-<a name="B.1" href="#B.1"><h3>B.1 Diagnostics <assert.h></h3></a>
+<h3><a name="B.1" href="#B.1">B.1 Diagnostics <assert.h></a></h3>
<pre>
NDEBUG
void assert(scalar expression);</pre>
-<a name="B.2" href="#B.2"><h3>B.2 Complex <complex.h></h3></a>
+<h3><a name="B.2" href="#B.2">B.2 Complex <complex.h></a></h3>
<!--page 432 -->
<!--page 433 -->
<pre>
float crealf(float complex z);
long double creall(long double complex z);</pre>
-<a name="B.3" href="#B.3"><h3>B.3 Character handling <ctype.h></h3></a>
+<h3><a name="B.3" href="#B.3">B.3 Character handling <ctype.h></a></h3>
<pre>
int isalnum(int c);
int isalpha(int c);
int tolower(int c);
int toupper(int c);</pre>
-<a name="B.4" href="#B.4"><h3>B.4 Errors <errno.h></h3></a>
+<h3><a name="B.4" href="#B.4">B.4 Errors <errno.h></a></h3>
<pre>
EDOM EILSEQ ERANGE errno</pre>
-<a name="B.5" href="#B.5"><h3>B.5 Floating-point environment <fenv.h></h3></a>
+<h3><a name="B.5" href="#B.5">B.5 Floating-point environment <fenv.h></a></h3>
<!--page 434 -->
<pre>
fenv_t FE_OVERFLOW FE_TOWARDZERO
int fesetenv(const fenv_t *envp);
int feupdateenv(const fenv_t *envp);</pre>
-<a name="B.6" href="#B.6"><h3>B.6 Characteristics of floating types <float.h></h3></a>
+<h3><a name="B.6" href="#B.6">B.6 Characteristics of floating types <float.h></a></h3>
<pre>
FLT_ROUNDS DBL_MIN_EXP FLT_MAX
FLT_EVAL_METHOD LDBL_MIN_EXP DBL_MAX
LDBL_DIG DBL_MAX_10_EXP
FLT_MIN_EXP LDBL_MAX_10_EXP</pre>
-<a name="B.7" href="#B.7"><h3>B.7 Format conversion of integer types <inttypes.h></h3></a>
+<h3><a name="B.7" href="#B.7">B.7 Format conversion of integer types <inttypes.h></a></h3>
<!--page 435 -->
<pre>
imaxdiv_t
uintmax_t wcstoumax(const wchar_t * restrict nptr,
wchar_t ** restrict endptr, int base);</pre>
-<a name="B.8" href="#B.8"><h3>B.8 Alternative spellings <iso646.h></h3></a>
+<h3><a name="B.8" href="#B.8">B.8 Alternative spellings <iso646.h></a></h3>
<pre>
and bitor not_eq xor
and_eq compl or xor_eq
bitand not or_eq</pre>
-<a name="B.9" href="#B.9"><h3>B.9 Sizes of integer types <limits.h></h3></a>
+<h3><a name="B.9" href="#B.9">B.9 Sizes of integer types <limits.h></a></h3>
<pre>
CHAR_BIT CHAR_MAX INT_MIN ULONG_MAX
SCHAR_MIN MB_LEN_MAX INT_MAX LLONG_MIN
UCHAR_MAX SHRT_MAX LONG_MIN ULLONG_MAX
CHAR_MIN USHRT_MAX LONG_MAX</pre>
-<a name="B.10" href="#B.10"><h3>B.10 Localization <locale.h></h3></a>
+<h3><a name="B.10" href="#B.10">B.10 Localization <locale.h></a></h3>
<pre>
struct lconv LC_ALL LC_CTYPE LC_NUMERIC
NULL LC_COLLATE LC_MONETARY LC_TIME
char *setlocale(int category, const char *locale);
struct lconv *localeconv(void);</pre>
-<a name="B.11" href="#B.11"><h3>B.11 Mathematics <math.h></h3></a>
+<h3><a name="B.11" href="#B.11">B.11 Mathematics <math.h></a></h3>
<!--page 436 -->
<!--page 437 -->
<!--page 438 -->
int islessgreater(real-floating x, real-floating y);
int isunordered(real-floating x, real-floating y);</pre>
-<a name="B.12" href="#B.12"><h3>B.12 Nonlocal jumps <setjmp.h></h3></a>
+<h3><a name="B.12" href="#B.12">B.12 Nonlocal jumps <setjmp.h></a></h3>
<pre>
jmp_buf
int setjmp(jmp_buf env);
void longjmp(jmp_buf env, int val);</pre>
-<a name="B.13" href="#B.13"><h3>B.13 Signal handling <signal.h></h3></a>
+<h3><a name="B.13" href="#B.13">B.13 Signal handling <signal.h></a></h3>
<pre>
sig_atomic_t SIG_IGN SIGILL SIGTERM
SIG_DFL SIGABRT SIGINT
void (*signal(int sig, void (*func)(int)))(int);
int raise(int sig);</pre>
-<a name="B.14" href="#B.14"><h3>B.14 Variable arguments <stdarg.h></h3></a>
+<h3><a name="B.14" href="#B.14">B.14 Variable arguments <stdarg.h></a></h3>
<pre>
va_list
type va_arg(va_list ap, type);
void va_end(va_list ap);
void va_start(va_list ap, parmN);</pre>
-<a name="B.15" href="#B.15"><h3>B.15 Boolean type and values <stdbool.h></h3></a>
+<h3><a name="B.15" href="#B.15">B.15 Boolean type and values <stdbool.h></a></h3>
<!--page 441 -->
<pre>
bool
false
__bool_true_false_are_defined</pre>
-<a name="B.16" href="#B.16"><h3>B.16 Common definitions <stddef.h></h3></a>
+<h3><a name="B.16" href="#B.16">B.16 Common definitions <stddef.h></a></h3>
<pre>
ptrdiff_t size_t wchar_t NULL
offsetof(type, member-designator)</pre>
-<a name="B.17" href="#B.17"><h3>B.17 Integer types <stdint.h></h3></a>
+<h3><a name="B.17" href="#B.17">B.17 Integer types <stdint.h></a></h3>
<pre>
intN_t INT_LEASTN_MIN PTRDIFF_MAX
uintN_t INT_LEASTN_MAX SIG_ATOMIC_MIN
INTN_MAX UINTMAX_MAX UINTMAX_C(value)
UINTN_MAX PTRDIFF_MIN</pre>
-<a name="B.18" href="#B.18"><h3>B.18 Input/output <stdio.h></h3></a>
+<h3><a name="B.18" href="#B.18">B.18 Input/output <stdio.h></a></h3>
<!--page 442 -->
<!--page 443 -->
<pre>
int ferror(FILE *stream);
void perror(const char *s);</pre>
-<a name="B.19" href="#B.19"><h3>B.19 General utilities <stdlib.h></h3></a>
+<h3><a name="B.19" href="#B.19">B.19 General utilities <stdlib.h></a></h3>
<!--page 444 -->
<!--page 445 -->
<pre>
size_t wcstombs(char * restrict s,
const wchar_t * restrict pwcs, size_t n);</pre>
-<a name="B.20" href="#B.20"><h3>B.20 String handling <string.h></h3></a>
+<h3><a name="B.20" href="#B.20">B.20 String handling <string.h></a></h3>
<!--page 446 -->
<pre>
size_t
char *strerror(int errnum);
size_t strlen(const char *s);</pre>
-<a name="B.21" href="#B.21"><h3>B.21 Type-generic math <tgmath.h></h3></a>
+<h3><a name="B.21" href="#B.21">B.21 Type-generic math <tgmath.h></a></h3>
<pre>
acos sqrt fmod nextafter
asin fabs frexp nexttoward
log fmax lround cproj
pow fmin nearbyint creal</pre>
-<a name="B.22" href="#B.22"><h3>B.22 Date and time <time.h></h3></a>
+<h3><a name="B.22" href="#B.22">B.22 Date and time <time.h></a></h3>
<!--page 447 -->
<pre>
NULL size_t time_t
const char * restrict format,
const struct tm * restrict timeptr);</pre>
-<a name="B.23" href="#B.23"><h3>B.23 Extended multibyte/wide character utilities <wchar.h></h3></a>
+<h3><a name="B.23" href="#B.23">B.23 Extended multibyte/wide character utilities <wchar.h></a></h3>
<!--page 448 -->
<!--page 449 -->
<pre>
const wchar_t ** restrict src, size_t len,
mbstate_t * restrict ps);</pre>
-<a name="B.24" href="#B.24"><h3>B.24 Wide character classification and mapping utilities <wctype.h></h3></a>
+<h3><a name="B.24" href="#B.24">B.24 Wide character classification and mapping utilities <wctype.h></a></h3>
<!--page 450 -->
<!--page 451 -->
<pre>
wint_t towctrans(wint_t wc, wctrans_t desc);
wctrans_t wctrans(const char *property);</pre>
-<a name="C" href="#C"><h2>Annex C</h2></a>
+<h2><a name="C" href="#C">Annex C</a></h2>
<p><!--para 1 -->
<pre>
(informative)
<!--page 452 -->
</ul>
-<a name="D" href="#D"><h2>Annex D</h2></a>
+<h2><a name="D" href="#D">Annex D</a></h2>
<p><!--para 1 -->
<pre>
(normative)
2107, 210A-2113, 2115, 2118-211D, 2124, 2126, 2128, 212A-2131,
2133-2138, 2160-2182, 3005-3007, 3021-3029</pre>
-<a name="E" href="#E"><h2>Annex E</h2></a>
+<h2><a name="E" href="#E">Annex E</a></h2>
<p><!--para 1 -->
<pre>
(informative)
- Implementation limits</pre>
+<h6> Implementation limits</h6></pre>
The contents of the header <a href="#7.10"><limits.h></a> are given below, in alphabetical order. The
minimum magnitudes shown shall be replaced by implementation-defined magnitudes
with the same sign. The values shall all be constant expressions suitable for use in #if
#define LDBL_EPSILON 1E-9
#define LDBL_MIN 1E-37</pre>
-<a name="F" href="#F"><h2>Annex F</h2></a>
+<h2><a name="F" href="#F">Annex F</a></h2>
<pre>
(normative)
IEC 60559 floating-point arithmetic</pre>
-<a name="F.1" href="#F.1"><h3>F.1 Introduction</h3></a>
+<h3><a name="F.1" href="#F.1">F.1 Introduction</a></h3>
<p><!--para 1 -->
This annex specifies C language support for the IEC 60559 floating-point standard. The
IEC 60559 floating-point standard is specifically Binary floating-point arithmetic for
a binding between the C language and IEC 60559 is indicated, the IEC 60559-specified
behavior is adopted by reference, unless stated otherwise.
-<a name="F.2" href="#F.2"><h3>F.2 Types</h3></a>
+<h3><a name="F.2" href="#F.2">F.2 Types</a></h3>
<p><!--para 1 -->
The C floating types match the IEC 60559 formats as follows:
<ul>
</ul>
Any non-IEC 60559 extended format used for the long double type shall have more
precision than IEC 60559 double and at least the range of IEC 60559 double.<sup><a href="#note308"><b>308)</b></a></sup>
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 2 -->
The long double type should match an IEC 60559 extended format.
all double values.
</small>
-<a name="F.2.1" href="#F.2.1"><h4>F.2.1 Infinities, signed zeros, and NaNs</h4></a>
+<h4><a name="F.2.1" href="#F.2.1">F.2.1 Infinities, signed zeros, and NaNs</a></h4>
<p><!--para 1 -->
This specification does not define the behavior of signaling NaNs.<sup><a href="#note309"><b>309)</b></a></sup> It generally uses
the term NaN to denote quiet NaNs. The NAN and INFINITY macros and the nan
sufficient for closure of the arithmetic.
</small>
-<a name="F.3" href="#F.3"><h3>F.3 Operators and functions</h3></a>
+<h3><a name="F.3" href="#F.3">F.3 Operators and functions</a></h3>
<p><!--para 1 -->
C operators and functions provide IEC 60559 required and recommended facilities as
listed below.
macros defined in <a href="#7.12.3">7.12.3</a> do not distinguish signaling from quiet NaNs).
</ul>
-<a name="F.4" href="#F.4"><h3>F.4 Floating to integer conversion</h3></a>
+<h3><a name="F.4" href="#F.4">F.4 Floating to integer conversion</a></h3>
<p><!--para 1 -->
If the floating value is infinite or NaN or if the integral part of the floating value exceeds
the range of the integer type, then the ''invalid'' floating-point exception is raised and the
<a href="#7.12"><math.h></a>.
</small>
-<a name="F.5" href="#F.5"><h3>F.5 Binary-decimal conversion</h3></a>
+<h3><a name="F.5" href="#F.5">F.5 Binary-decimal conversion</a></h3>
<p><!--para 1 -->
Conversion from the widest supported IEC 60559 format to decimal with
DECIMAL_DIG digits and back is the identity function.<sup><a href="#note311"><b>311)</b></a></sup>
DBL_DIG are 18 and 15, respectively, for these formats.)
</small>
-<a name="F.6" href="#F.6"><h3>F.6 Contracted expressions</h3></a>
+<h3><a name="F.6" href="#F.6">F.6 Contracted expressions</a></h3>
<p><!--para 1 -->
A contracted expression treats infinities, NaNs, signed zeros, subnormals, and the
rounding directions in a manner consistent with the basic arithmetic operations covered
by IEC 60559.
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 2 -->
A contracted expression should raise floating-point exceptions in a manner generally
consistent with the basic arithmetic operations. A contracted expression should deliver
the same value as its uncontracted counterpart, else should be correctly rounded (once).
-<a name="F.7" href="#F.7"><h3>F.7 Floating-point environment</h3></a>
+<h3><a name="F.7" href="#F.7">F.7 Floating-point environment</a></h3>
<p><!--para 1 -->
The floating-point environment defined in <a href="#7.6"><fenv.h></a> includes the IEC 60559 floating-
point exception status flags and directed-rounding control modes. It includes also
<p><small><a name="note312" href="#note312">312)</a> This specification does not require dynamic rounding precision nor trap enablement modes.
</small>
-<a name="F.7.1" href="#F.7.1"><h4>F.7.1 Environment management</h4></a>
+<h4><a name="F.7.1" href="#F.7.1">F.7.1 Environment management</a></h4>
<p><!--para 1 -->
IEC 60559 requires that floating-point operations implicitly raise floating-point exception
status flags, and that rounding control modes can be set explicitly to affect result values of
which allows certain optimizations (see <a href="#F.8">F.8</a>).
</small>
-<a name="F.7.2" href="#F.7.2"><h4>F.7.2 Translation</h4></a>
+<h4><a name="F.7.2" href="#F.7.2">F.7.2 Translation</a></h4>
<p><!--para 1 -->
During translation the IEC 60559 default modes are in effect:
<ul>
<li> The rounding precision mode (if supported) is set so that results are not shortened.
<li> Trapping or stopping (if supported) is disabled on all floating-point exceptions.
</ul>
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 2 -->
The implementation should produce a diagnostic message for each translation-time
strtod, provide execution-time conversion of numeric strings.
</small>
-<a name="F.7.3" href="#F.7.3"><h4>F.7.3 Execution</h4></a>
+<h4><a name="F.7.3" href="#F.7.3">F.7.3 Execution</a></h4>
<p><!--para 1 -->
At program startup the floating-point environment is initialized as prescribed by
IEC 60559:
<li> Trapping or stopping (if supported) is disabled on all floating-point exceptions.
</ul>
-<a name="F.7.4" href="#F.7.4"><h4>F.7.4 Constant expressions</h4></a>
+<h4><a name="F.7.4" href="#F.7.4">F.7.4 Constant expressions</a></h4>
<p><!--para 1 -->
An arithmetic constant expression of floating type, other than one in an initializer for an
object that has static storage duration, is evaluated (as if) during execution; thus, it is
const static double one_third = 1.0/3.0;</pre>
</small>
-<a name="F.7.5" href="#F.7.5"><h4>F.7.5 Initialization</h4></a>
+<h4><a name="F.7.5" href="#F.7.5">F.7.5 Initialization</a></h4>
<p><!--para 1 -->
All computation for automatic initialization is done (as if) at execution time; thus, it is
affected by any operative modes and raises floating-point exceptions as required by
could be done at translation time, regardless of the expression evaluation method.
</small>
-<a name="F.7.6" href="#F.7.6"><h4>F.7.6 Changing the environment</h4></a>
+<h4><a name="F.7.6" href="#F.7.6">F.7.6 Changing the environment</a></h4>
<p><!--para 1 -->
Operations defined in <a href="#6.5">6.5</a> and functions and macros defined for the standard libraries
change floating-point status flags and control modes just as indicated by their
''inexact'', or ''underflow'' and ''inexact''), then ''overflow'' or ''underflow'' is raised
before ''inexact''.
-<a name="F.8" href="#F.8"><h3>F.8 Optimization</h3></a>
+<h3><a name="F.8" href="#F.8">F.8 Optimization</a></h3>
<p><!--para 1 -->
This section identifies code transformations that might subvert IEC 60559-specified
behavior, and others that do not.
-<a name="F.8.1" href="#F.8.1"><h4>F.8.1 Global transformations</h4></a>
+<h4><a name="F.8.1" href="#F.8.1">F.8.1 Global transformations</a></h4>
<p><!--para 1 -->
Floating-point arithmetic operations and external function calls may entail side effects
which optimization shall honor, at least where the state of the FENV_ACCESS pragma is
<pre>
if (0 < n) x + 1;</pre>
-<a name="F.8.2" href="#F.8.2"><h4>F.8.2 Expression transformations</h4></a>
+<h4><a name="F.8.2" href="#F.8.2">F.8.2 Expression transformations</a></h4>
<p><!--para 1 -->
x / 2 <-> x * 0.5 Although similar transformations involving inexact
<pre>
for complex z.
</small>
-<a name="F.8.3" href="#F.8.3"><h4>F.8.3 Relational operators</h4></a>
+<h4><a name="F.8.3" href="#F.8.3">F.8.3 Relational operators</a></h4>
<p><!--para 1 -->
x != x -> false The statement x != x is true if x is a NaN.
x == x -> true The statement x == x is false if x is a NaN.
f();</pre>
-<a name="F.8.4" href="#F.8.4"><h4>F.8.4 Constant arithmetic</h4></a>
+<h4><a name="F.8.4" href="#F.8.4">F.8.4 Constant arithmetic</a></h4>
<p><!--para 1 -->
The implementation shall honor floating-point exceptions raised by execution-time
constant arithmetic wherever the state of the FENV_ACCESS pragma is ''on''. (See <a href="#F.7.4">F.7.4</a>
<p><small><a name="note319" href="#note319">319)</a> 0 - 0 yields -0 instead of +0 just when the rounding direction is downward.
</small>
-<a name="F.9" href="#F.9"><h3>F.9 Mathematics <math.h></h3></a>
+<h3><a name="F.9" href="#F.9">F.9 Mathematics <math.h></a></h3>
<p><!--para 1 -->
This subclause contains specifications of <a href="#7.12"><math.h></a> facilities that are particularly suited
for IEC 60559 implementations.
For families of functions, the specifications apply to all of the functions even though only
the principal function is shown. Unless otherwise specified, where the symbol ''(+-)''
occurs in both an argument and the result, the result has the same sign as the argument.
- Recommended practice
+<h6> Recommended practice</h6>
<p><!--para 13 -->
If a function with one or more NaN arguments returns a NaN result, the result should be
the same as one of the NaN arguments (after possible type conversion), except perhaps
avoiding them would be too costly.
</small>
-<a name="F.9.1" href="#F.9.1"><h4>F.9.1 Trigonometric functions</h4></a>
+<h4><a name="F.9.1" href="#F.9.1">F.9.1 Trigonometric functions</a></h4>
-<a name="F.9.1.1" href="#F.9.1.1"><h5>F.9.1.1 The acos functions</h5></a>
+<h5><a name="F.9.1.1" href="#F.9.1.1">F.9.1.1 The acos functions</a></h5>
<p><!--para 1 -->
<ul>
<li> acos(1) returns +0.
<!--page 468 -->
</ul>
-<a name="F.9.1.2" href="#F.9.1.2"><h5>F.9.1.2 The asin functions</h5></a>
+<h5><a name="F.9.1.2" href="#F.9.1.2">F.9.1.2 The asin functions</a></h5>
<p><!--para 1 -->
<ul>
<li> asin((+-)0) returns (+-)0.
| x | > 1.
</ul>
-<a name="F.9.1.3" href="#F.9.1.3"><h5>F.9.1.3 The atan functions</h5></a>
+<h5><a name="F.9.1.3" href="#F.9.1.3">F.9.1.3 The atan functions</a></h5>
<p><!--para 1 -->
<ul>
<li> atan((+-)0) returns (+-)0.
<li> atan((+-)(inf)) returns (+-)pi /2.
</ul>
-<a name="F.9.1.4" href="#F.9.1.4"><h5>F.9.1.4 The atan2 functions</h5></a>
+<h5><a name="F.9.1.4" href="#F.9.1.4">F.9.1.4 The atan2 functions</a></h5>
<p><!--para 1 -->
<ul>
<li> atan2((+-)0, -0) returns (+-)pi .<sup><a href="#note322"><b>322)</b></a></sup>
the ''divide-by-zero'' floating-point exception.
</small>
-<a name="F.9.1.5" href="#F.9.1.5"><h5>F.9.1.5 The cos functions</h5></a>
+<h5><a name="F.9.1.5" href="#F.9.1.5">F.9.1.5 The cos functions</a></h5>
<p><!--para 1 -->
<ul>
<li> cos((+-)0) returns 1.
<li> cos((+-)(inf)) returns a NaN and raises the ''invalid'' floating-point exception.
</ul>
-<a name="F.9.1.6" href="#F.9.1.6"><h5>F.9.1.6 The sin functions</h5></a>
+<h5><a name="F.9.1.6" href="#F.9.1.6">F.9.1.6 The sin functions</a></h5>
<p><!--para 1 -->
<ul>
<li> sin((+-)0) returns (+-)0.
<!--page 469 -->
</ul>
-<a name="F.9.1.7" href="#F.9.1.7"><h5>F.9.1.7 The tan functions</h5></a>
+<h5><a name="F.9.1.7" href="#F.9.1.7">F.9.1.7 The tan functions</a></h5>
<p><!--para 1 -->
<ul>
<li> tan((+-)0) returns (+-)0.
<li> tan((+-)(inf)) returns a NaN and raises the ''invalid'' floating-point exception.
</ul>
-<a name="F.9.2" href="#F.9.2"><h4>F.9.2 Hyperbolic functions</h4></a>
+<h4><a name="F.9.2" href="#F.9.2">F.9.2 Hyperbolic functions</a></h4>
-<a name="F.9.2.1" href="#F.9.2.1"><h5>F.9.2.1 The acosh functions</h5></a>
+<h5><a name="F.9.2.1" href="#F.9.2.1">F.9.2.1 The acosh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> acosh(1) returns +0.
<li> acosh(+(inf)) returns +(inf).
</ul>
-<a name="F.9.2.2" href="#F.9.2.2"><h5>F.9.2.2 The asinh functions</h5></a>
+<h5><a name="F.9.2.2" href="#F.9.2.2">F.9.2.2 The asinh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> asinh((+-)0) returns (+-)0.
<li> asinh((+-)(inf)) returns (+-)(inf).
</ul>
-<a name="F.9.2.3" href="#F.9.2.3"><h5>F.9.2.3 The atanh functions</h5></a>
+<h5><a name="F.9.2.3" href="#F.9.2.3">F.9.2.3 The atanh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> atanh((+-)0) returns (+-)0.
| x | > 1.
</ul>
-<a name="F.9.2.4" href="#F.9.2.4"><h5>F.9.2.4 The cosh functions</h5></a>
+<h5><a name="F.9.2.4" href="#F.9.2.4">F.9.2.4 The cosh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> cosh((+-)0) returns 1.
<li> cosh((+-)(inf)) returns +(inf).
</ul>
-<a name="F.9.2.5" href="#F.9.2.5"><h5>F.9.2.5 The sinh functions</h5></a>
+<h5><a name="F.9.2.5" href="#F.9.2.5">F.9.2.5 The sinh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> sinh((+-)0) returns (+-)0.
<li> sinh((+-)(inf)) returns (+-)(inf).
</ul>
-<a name="F.9.2.6" href="#F.9.2.6"><h5>F.9.2.6 The tanh functions</h5></a>
+<h5><a name="F.9.2.6" href="#F.9.2.6">F.9.2.6 The tanh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> tanh((+-)0) returns (+-)0.
<!--page 470 -->
</ul>
-<a name="F.9.3" href="#F.9.3"><h4>F.9.3 Exponential and logarithmic functions</h4></a>
+<h4><a name="F.9.3" href="#F.9.3">F.9.3 Exponential and logarithmic functions</a></h4>
-<a name="F.9.3.1" href="#F.9.3.1"><h5>F.9.3.1 The exp functions</h5></a>
+<h5><a name="F.9.3.1" href="#F.9.3.1">F.9.3.1 The exp functions</a></h5>
<p><!--para 1 -->
<ul>
<li> exp((+-)0) returns 1.
<li> exp(+(inf)) returns +(inf).
</ul>
-<a name="F.9.3.2" href="#F.9.3.2"><h5>F.9.3.2 The exp2 functions</h5></a>
+<h5><a name="F.9.3.2" href="#F.9.3.2">F.9.3.2 The exp2 functions</a></h5>
<p><!--para 1 -->
<ul>
<li> exp2((+-)0) returns 1.
<li> exp2(+(inf)) returns +(inf).
</ul>
-<a name="F.9.3.3" href="#F.9.3.3"><h5>F.9.3.3 The expm1 functions</h5></a>
+<h5><a name="F.9.3.3" href="#F.9.3.3">F.9.3.3 The expm1 functions</a></h5>
<p><!--para 1 -->
<ul>
<li> expm1((+-)0) returns (+-)0.
<li> expm1(+(inf)) returns +(inf).
</ul>
-<a name="F.9.3.4" href="#F.9.3.4"><h5>F.9.3.4 The frexp functions</h5></a>
+<h5><a name="F.9.3.4" href="#F.9.3.4">F.9.3.4 The frexp functions</a></h5>
<p><!--para 1 -->
<ul>
<li> frexp((+-)0, exp) returns (+-)0, and stores 0 in the object pointed to by exp.
return scalbn(value, -(*exp));
}</pre>
-<a name="F.9.3.5" href="#F.9.3.5"><h5>F.9.3.5 The ilogb functions</h5></a>
+<h5><a name="F.9.3.5" href="#F.9.3.5">F.9.3.5 The ilogb functions</a></h5>
<p><!--para 1 -->
If the correct result is outside the range of the return type, the numeric result is
unspecified and the ''invalid'' floating-point exception is raised.
<!--page 471 -->
-<a name="F.9.3.6" href="#F.9.3.6"><h5>F.9.3.6 The ldexp functions</h5></a>
+<h5><a name="F.9.3.6" href="#F.9.3.6">F.9.3.6 The ldexp functions</a></h5>
<p><!--para 1 -->
On a binary system, ldexp(x, exp) is equivalent to scalbn(x, exp).
-<a name="F.9.3.7" href="#F.9.3.7"><h5>F.9.3.7 The log functions</h5></a>
+<h5><a name="F.9.3.7" href="#F.9.3.7">F.9.3.7 The log functions</a></h5>
<p><!--para 1 -->
<ul>
<li> log((+-)0) returns -(inf) and raises the ''divide-by-zero'' floating-point exception.
<li> log(+(inf)) returns +(inf).
</ul>
-<a name="F.9.3.8" href="#F.9.3.8"><h5>F.9.3.8 The log10 functions</h5></a>
+<h5><a name="F.9.3.8" href="#F.9.3.8">F.9.3.8 The log10 functions</a></h5>
<p><!--para 1 -->
<ul>
<li> log10((+-)0) returns -(inf) and raises the ''divide-by-zero'' floating-point exception.
<li> log10(+(inf)) returns +(inf).
</ul>
-<a name="F.9.3.9" href="#F.9.3.9"><h5>F.9.3.9 The log1p functions</h5></a>
+<h5><a name="F.9.3.9" href="#F.9.3.9">F.9.3.9 The log1p functions</a></h5>
<p><!--para 1 -->
<ul>
<li> log1p((+-)0) returns (+-)0.
<li> log1p(+(inf)) returns +(inf).
</ul>
-<a name="F.9.3.10" href="#F.9.3.10"><h5>F.9.3.10 The log2 functions</h5></a>
+<h5><a name="F.9.3.10" href="#F.9.3.10">F.9.3.10 The log2 functions</a></h5>
<p><!--para 1 -->
<ul>
<li> log2((+-)0) returns -(inf) and raises the ''divide-by-zero'' floating-point exception.
<li> log2(+(inf)) returns +(inf).
</ul>
-<a name="F.9.3.11" href="#F.9.3.11"><h5>F.9.3.11 The logb functions</h5></a>
+<h5><a name="F.9.3.11" href="#F.9.3.11">F.9.3.11 The logb functions</a></h5>
<p><!--para 1 -->
<ul>
<li> logb((+-)0) returns -(inf) and raises the ''divide-by-zero'' floating-point exception.
<!--page 472 -->
</ul>
-<a name="F.9.3.12" href="#F.9.3.12"><h5>F.9.3.12 The modf functions</h5></a>
+<h5><a name="F.9.3.12" href="#F.9.3.12">F.9.3.12 The modf functions</a></h5>
<p><!--para 1 -->
<ul>
<li> modf((+-)x, iptr) returns a result with the same sign as x.
value - (*iptr), value);
}</pre>
-<a name="F.9.3.13" href="#F.9.3.13"><h5>F.9.3.13 The scalbn and scalbln functions</h5></a>
+<h5><a name="F.9.3.13" href="#F.9.3.13">F.9.3.13 The scalbn and scalbln functions</a></h5>
<p><!--para 1 -->
<ul>
<li> scalbn((+-)0, n) returns (+-)0.
<li> scalbn((+-)(inf), n) returns (+-)(inf).
</ul>
-<a name="F.9.4" href="#F.9.4"><h4>F.9.4 Power and absolute value functions</h4></a>
+<h4><a name="F.9.4" href="#F.9.4">F.9.4 Power and absolute value functions</a></h4>
-<a name="F.9.4.1" href="#F.9.4.1"><h5>F.9.4.1 The cbrt functions</h5></a>
+<h5><a name="F.9.4.1" href="#F.9.4.1">F.9.4.1 The cbrt functions</a></h5>
<p><!--para 1 -->
<ul>
<li> cbrt((+-)0) returns (+-)0.
<li> cbrt((+-)(inf)) returns (+-)(inf).
</ul>
-<a name="F.9.4.2" href="#F.9.4.2"><h5>F.9.4.2 The fabs functions</h5></a>
+<h5><a name="F.9.4.2" href="#F.9.4.2">F.9.4.2 The fabs functions</a></h5>
<p><!--para 1 -->
<ul>
<li> fabs((+-)0) returns +0.
<!--page 473 -->
</ul>
-<a name="F.9.4.3" href="#F.9.4.3"><h5>F.9.4.3 The hypot functions</h5></a>
+<h5><a name="F.9.4.3" href="#F.9.4.3">F.9.4.3 The hypot functions</a></h5>
<p><!--para 1 -->
<ul>
<li> hypot(x, y), hypot(y, x), and hypot(x, -y) are equivalent.
<li> hypot((+-)(inf), y) returns +(inf), even if y is a NaN.
</ul>
-<a name="F.9.4.4" href="#F.9.4.4"><h5>F.9.4.4 The pow functions</h5></a>
+<h5><a name="F.9.4.4" href="#F.9.4.4">F.9.4.4 The pow functions</a></h5>
<p><!--para 1 -->
<ul>
<li> pow((+-)0, y) returns (+-)(inf) and raises the ''divide-by-zero'' floating-point exception
<!--page 474 -->
</ul>
-<a name="F.9.4.5" href="#F.9.4.5"><h5>F.9.4.5 The sqrt functions</h5></a>
+<h5><a name="F.9.4.5" href="#F.9.4.5">F.9.4.5 The sqrt functions</a></h5>
<p><!--para 1 -->
sqrt is fully specified as a basic arithmetic operation in IEC 60559.
-<a name="F.9.5" href="#F.9.5"><h4>F.9.5 Error and gamma functions</h4></a>
+<h4><a name="F.9.5" href="#F.9.5">F.9.5 Error and gamma functions</a></h4>
-<a name="F.9.5.1" href="#F.9.5.1"><h5>F.9.5.1 The erf functions</h5></a>
+<h5><a name="F.9.5.1" href="#F.9.5.1">F.9.5.1 The erf functions</a></h5>
<p><!--para 1 -->
<ul>
<li> erf((+-)0) returns (+-)0.
<li> erf((+-)(inf)) returns (+-)1.
</ul>
-<a name="F.9.5.2" href="#F.9.5.2"><h5>F.9.5.2 The erfc functions</h5></a>
+<h5><a name="F.9.5.2" href="#F.9.5.2">F.9.5.2 The erfc functions</a></h5>
<p><!--para 1 -->
<ul>
<li> erfc(-(inf)) returns 2.
<li> erfc(+(inf)) returns +0.
</ul>
-<a name="F.9.5.3" href="#F.9.5.3"><h5>F.9.5.3 The lgamma functions</h5></a>
+<h5><a name="F.9.5.3" href="#F.9.5.3">F.9.5.3 The lgamma functions</a></h5>
<p><!--para 1 -->
<ul>
<li> lgamma(1) returns +0.
<li> lgamma(+(inf)) returns +(inf).
</ul>
-<a name="F.9.5.4" href="#F.9.5.4"><h5>F.9.5.4 The tgamma functions</h5></a>
+<h5><a name="F.9.5.4" href="#F.9.5.4">F.9.5.4 The tgamma functions</a></h5>
<p><!--para 1 -->
<ul>
<li> tgamma((+-)0) returns (+-)(inf) and raises the ''divide-by-zero'' floating-point exception.
<li> tgamma(+(inf)) returns +(inf).
</ul>
-<a name="F.9.6" href="#F.9.6"><h4>F.9.6 Nearest integer functions</h4></a>
+<h4><a name="F.9.6" href="#F.9.6">F.9.6 Nearest integer functions</a></h4>
-<a name="F.9.6.1" href="#F.9.6.1"><h5>F.9.6.1 The ceil functions</h5></a>
+<h5><a name="F.9.6.1" href="#F.9.6.1">F.9.6.1 The ceil functions</a></h5>
<p><!--para 1 -->
<ul>
<li> ceil((+-)0) returns (+-)0.
return result;
}</pre>
-<a name="F.9.6.2" href="#F.9.6.2"><h5>F.9.6.2 The floor functions</h5></a>
+<h5><a name="F.9.6.2" href="#F.9.6.2">F.9.6.2 The floor functions</a></h5>
<p><!--para 1 -->
<ul>
<li> floor((+-)0) returns (+-)0.
<p><!--para 2 -->
See the sample implementation for ceil in <a href="#F.9.6.1">F.9.6.1</a>.
-<a name="F.9.6.3" href="#F.9.6.3"><h5>F.9.6.3 The nearbyint functions</h5></a>
+<h5><a name="F.9.6.3" href="#F.9.6.3">F.9.6.3 The nearbyint functions</a></h5>
<p><!--para 1 -->
The nearbyint functions use IEC 60559 rounding according to the current rounding
direction. They do not raise the ''inexact'' floating-point exception if the result differs in
<li> nearbyint((+-)(inf)) returns (+-)(inf) (for all rounding directions).
</ul>
-<a name="F.9.6.4" href="#F.9.6.4"><h5>F.9.6.4 The rint functions</h5></a>
+<h5><a name="F.9.6.4" href="#F.9.6.4">F.9.6.4 The rint functions</a></h5>
<p><!--para 1 -->
The rint functions differ from the nearbyint functions only in that they do raise the
''inexact'' floating-point exception if the result differs in value from the argument.
-<a name="F.9.6.5" href="#F.9.6.5"><h5>F.9.6.5 The lrint and llrint functions</h5></a>
+<h5><a name="F.9.6.5" href="#F.9.6.5">F.9.6.5 The lrint and llrint functions</a></h5>
<p><!--para 1 -->
The lrint and llrint functions provide floating-to-integer conversion as prescribed
by IEC 60559. They round according to the current rounding direction. If the rounded
exception.
<!--page 476 -->
-<a name="F.9.6.6" href="#F.9.6.6"><h5>F.9.6.6 The round functions</h5></a>
+<h5><a name="F.9.6.6" href="#F.9.6.6">F.9.6.6 The round functions</a></h5>
<p><!--para 1 -->
<ul>
<li> round((+-)0) returns (+-)0.
The round functions may, but are not required to, raise the ''inexact'' floating-point
exception for non-integer numeric arguments, as this implementation does.
-<a name="F.9.6.7" href="#F.9.6.7"><h5>F.9.6.7 The lround and llround functions</h5></a>
+<h5><a name="F.9.6.7" href="#F.9.6.7">F.9.6.7 The lround and llround functions</a></h5>
<p><!--para 1 -->
The lround and llround functions differ from the lrint and llrint functions
with the default rounding direction just in that the lround and llround functions
round halfway cases away from zero and need not raise the ''inexact'' floating-point
exception for non-integer arguments that round to within the range of the return type.
-<a name="F.9.6.8" href="#F.9.6.8"><h5>F.9.6.8 The trunc functions</h5></a>
+<h5><a name="F.9.6.8" href="#F.9.6.8">F.9.6.8 The trunc functions</a></h5>
<p><!--para 1 -->
The trunc functions use IEC 60559 rounding toward zero (regardless of the current
rounding direction).
<!--page 477 -->
</ul>
-<a name="F.9.7" href="#F.9.7"><h4>F.9.7 Remainder functions</h4></a>
+<h4><a name="F.9.7" href="#F.9.7">F.9.7 Remainder functions</a></h4>
-<a name="F.9.7.1" href="#F.9.7.1"><h5>F.9.7.1 The fmod functions</h5></a>
+<h5><a name="F.9.7.1" href="#F.9.7.1">F.9.7.1 The fmod functions</a></h5>
<p><!--para 1 -->
<ul>
<li> fmod((+-)0, y) returns (+-)0 for y not zero.
return copysign(result, x);
}</pre>
-<a name="F.9.7.2" href="#F.9.7.2"><h5>F.9.7.2 The remainder functions</h5></a>
+<h5><a name="F.9.7.2" href="#F.9.7.2">F.9.7.2 The remainder functions</a></h5>
<p><!--para 1 -->
The remainder functions are fully specified as a basic arithmetic operation in
IEC 60559.
-<a name="F.9.7.3" href="#F.9.7.3"><h5>F.9.7.3 The remquo functions</h5></a>
+<h5><a name="F.9.7.3" href="#F.9.7.3">F.9.7.3 The remquo functions</a></h5>
<p><!--para 1 -->
The remquo functions follow the specifications for the remainder functions. They
have no further specifications special to IEC 60559 implementations.
-<a name="F.9.8" href="#F.9.8"><h4>F.9.8 Manipulation functions</h4></a>
+<h4><a name="F.9.8" href="#F.9.8">F.9.8 Manipulation functions</a></h4>
-<a name="F.9.8.1" href="#F.9.8.1"><h5>F.9.8.1 The copysign functions</h5></a>
+<h5><a name="F.9.8.1" href="#F.9.8.1">F.9.8.1 The copysign functions</a></h5>
<p><!--para 1 -->
copysign is specified in the Appendix to IEC 60559.
-<a name="F.9.8.2" href="#F.9.8.2"><h5>F.9.8.2 The nan functions</h5></a>
+<h5><a name="F.9.8.2" href="#F.9.8.2">F.9.8.2 The nan functions</a></h5>
<p><!--para 1 -->
All IEC 60559 implementations support quiet NaNs, in all floating formats.
<!--page 478 -->
-<a name="F.9.8.3" href="#F.9.8.3"><h5>F.9.8.3 The nextafter functions</h5></a>
+<h5><a name="F.9.8.3" href="#F.9.8.3">F.9.8.3 The nextafter functions</a></h5>
<p><!--para 1 -->
<ul>
<li> nextafter(x, y) raises the ''overflow'' and ''inexact'' floating-point exceptions
exceptions for the function value subnormal or zero and x != y.
</ul>
-<a name="F.9.8.4" href="#F.9.8.4"><h5>F.9.8.4 The nexttoward functions</h5></a>
+<h5><a name="F.9.8.4" href="#F.9.8.4">F.9.8.4 The nexttoward functions</a></h5>
<p><!--para 1 -->
No additional requirements beyond those on nextafter.
-<a name="F.9.9" href="#F.9.9"><h4>F.9.9 Maximum, minimum, and positive difference functions</h4></a>
+<h4><a name="F.9.9" href="#F.9.9">F.9.9 Maximum, minimum, and positive difference functions</a></h4>
-<a name="F.9.9.1" href="#F.9.9.1"><h5>F.9.9.1 The fdim functions</h5></a>
+<h5><a name="F.9.9.1" href="#F.9.9.1">F.9.9.1 The fdim functions</a></h5>
<p><!--para 1 -->
No additional requirements.
-<a name="F.9.9.2" href="#F.9.9.2"><h5>F.9.9.2 The fmax functions</h5></a>
+<h5><a name="F.9.9.2" href="#F.9.9.2">F.9.9.2 The fmax functions</a></h5>
<p><!--para 1 -->
If just one argument is a NaN, the fmax functions return the other argument (if both
arguments are NaNs, the functions return a NaN).
return +0; however, implementation in software might be impractical.
</small>
-<a name="F.9.9.3" href="#F.9.9.3"><h5>F.9.9.3 The fmin functions</h5></a>
+<h5><a name="F.9.9.3" href="#F.9.9.3">F.9.9.3 The fmin functions</a></h5>
<p><!--para 1 -->
The fmin functions are analogous to the fmax functions (see <a href="#F.9.9.2">F.9.9.2</a>).
-<a name="F.9.10" href="#F.9.10"><h4>F.9.10 Floating multiply-add</h4></a>
+<h4><a name="F.9.10" href="#F.9.10">F.9.10 Floating multiply-add</a></h4>
-<a name="F.9.10.1" href="#F.9.10.1"><h5>F.9.10.1 The fma functions</h5></a>
+<h5><a name="F.9.10.1" href="#F.9.10.1">F.9.10.1 The fma functions</a></h5>
<p><!--para 1 -->
<ul>
<li> fma(x, y, z) computes xy + z, correctly rounded once.
<!--page 479 -->
</ul>
-<a name="G" href="#G"><h2>Annex G</h2></a>
+<h2><a name="G" href="#G">Annex G</a></h2>
<pre>
(informative)
IEC 60559-compatible complex arithmetic</pre>
-<a name="G.1" href="#G.1"><h3>G.1 Introduction</h3></a>
+<h3><a name="G.1" href="#G.1">G.1 Introduction</a></h3>
<p><!--para 1 -->
This annex supplements <a href="#F">annex F</a> to specify complex arithmetic for compatibility with
IEC 60559 real floating-point arithmetic. Although these specifications have been
recommended practice. An implementation that defines
__STDC_IEC_559_COMPLEX__ should conform to the specifications in this annex.
-<a name="G.2" href="#G.2"><h3>G.2 Types</h3></a>
+<h3><a name="G.2" href="#G.2">G.2 Types</a></h3>
<p><!--para 1 -->
There is a new keyword _Imaginary, which is used to specify imaginary types. It is
used as a type specifier within declaration specifiers in the same way as _Complex is
<p><!--para 5 -->
The imaginary type domain comprises the imaginary types.
-<a name="G.3" href="#G.3"><h3>G.3 Conventions</h3></a>
+<h3><a name="G.3" href="#G.3">G.3 Conventions</a></h3>
<p><!--para 1 -->
A complex or imaginary value with at least one infinite part is regarded as an infinity
(even if its other part is a NaN). A complex or imaginary value is a finite number if each
a zero if each of its parts is a zero.
<!--page 480 -->
-<a name="G.4" href="#G.4"><h3>G.4 Conversions</h3></a>
+<h3><a name="G.4" href="#G.4">G.4 Conversions</a></h3>
-<a name="G.4.1" href="#G.4.1"><h4>G.4.1 Imaginary types</h4></a>
+<h4><a name="G.4.1" href="#G.4.1">G.4.1 Imaginary types</a></h4>
<p><!--para 1 -->
Conversions among imaginary types follow rules analogous to those for real floating
types.
-<a name="G.4.2" href="#G.4.2"><h4>G.4.2 Real and imaginary</h4></a>
+<h4><a name="G.4.2" href="#G.4.2">G.4.2 Real and imaginary</a></h4>
<p><!--para 1 -->
When a value of imaginary type is converted to a real type other than _Bool,<sup><a href="#note324"><b>324)</b></a></sup> the
result is a positive zero.
<p><small><a name="note324" href="#note324">324)</a> See <a href="#6.3.1.2">6.3.1.2</a>.
</small>
-<a name="G.4.3" href="#G.4.3"><h4>G.4.3 Imaginary and complex</h4></a>
+<h4><a name="G.4.3" href="#G.4.3">G.4.3 Imaginary and complex</a></h4>
<p><!--para 1 -->
When a value of imaginary type is converted to a complex type, the real part of the
complex result value is a positive zero and the imaginary part of the complex result value
complex value is discarded and the value of the imaginary part is converted according to
the conversion rules for the corresponding real types.
-<a name="G.5" href="#G.5"><h3>G.5 Binary operators</h3></a>
+<h3><a name="G.5" href="#G.5">G.5 Binary operators</a></h3>
<p><!--para 1 -->
The following subclauses supplement <a href="#6.5">6.5</a> in order to specify the type of the result for an
operation with an imaginary operand.
<!--page 481 -->
-<a name="G.5.1" href="#G.5.1"><h4>G.5.1 Multiplicative operators</h4></a>
+<h4><a name="G.5.1" href="#G.5.1">G.5.1 Multiplicative operators</a></h4>
<h6>Semantics</h6>
<p><!--para 1 -->
If one operand has real type and the other operand has imaginary type, then the result has
(at least where the state for CX_LIMITED_RANGE is ''off'').
</small>
-<a name="G.5.2" href="#G.5.2"><h4>G.5.2 Additive operators</h4></a>
+<h4><a name="G.5.2" href="#G.5.2">G.5.2 Additive operators</a></h4>
<h6>Semantics</h6>
<p><!--para 1 -->
If both operands have imaginary type, then the result has imaginary type. (If one operand
<pre>
x + iy (x (+-) u) + iy x + i(y (+-) v) (x (+-) u) + i(y (+-) v)</pre>
-<a name="G.6" href="#G.6"><h3>G.6 Complex arithmetic <complex.h></h3></a>
+<h3><a name="G.6" href="#G.6">G.6 Complex arithmetic <complex.h></a></h3>
<p><!--para 1 -->
The macros
<pre>
other part is a NaN.
</small>
-<a name="G.6.1" href="#G.6.1"><h4>G.6.1 Trigonometric functions</h4></a>
+<h4><a name="G.6.1" href="#G.6.1">G.6.1 Trigonometric functions</a></h4>
-<a name="G.6.1.1" href="#G.6.1.1"><h5>G.6.1.1 The cacos functions</h5></a>
+<h5><a name="G.6.1.1" href="#G.6.1.1">G.6.1.1 The cacos functions</a></h5>
<p><!--para 1 -->
<ul>
<li> cacos(conj(z)) = conj(cacos(z)).
<li> cacos(NaN + iNaN) returns NaN + iNaN.
</ul>
-<a name="G.6.2" href="#G.6.2"><h4>G.6.2 Hyperbolic functions</h4></a>
+<h4><a name="G.6.2" href="#G.6.2">G.6.2 Hyperbolic functions</a></h4>
-<a name="G.6.2.1" href="#G.6.2.1"><h5>G.6.2.1 The cacosh functions</h5></a>
+<h5><a name="G.6.2.1" href="#G.6.2.1">G.6.2.1 The cacosh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> cacosh(conj(z)) = conj(cacosh(z)).
<li> cacosh(NaN + iNaN) returns NaN + iNaN.
</ul>
-<a name="G.6.2.2" href="#G.6.2.2"><h5>G.6.2.2 The casinh functions</h5></a>
+<h5><a name="G.6.2.2" href="#G.6.2.2">G.6.2.2 The casinh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> casinh(conj(z)) = conj(casinh(z)) and casinh is odd.
<li> casinh(NaN + iNaN) returns NaN + iNaN.
</ul>
-<a name="G.6.2.3" href="#G.6.2.3"><h5>G.6.2.3 The catanh functions</h5></a>
+<h5><a name="G.6.2.3" href="#G.6.2.3">G.6.2.3 The catanh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> catanh(conj(z)) = conj(catanh(z)) and catanh is odd.
<li> catanh(NaN + iNaN) returns NaN + iNaN.
</ul>
-<a name="G.6.2.4" href="#G.6.2.4"><h5>G.6.2.4 The ccosh functions</h5></a>
+<h5><a name="G.6.2.4" href="#G.6.2.4">G.6.2.4 The ccosh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> ccosh(conj(z)) = conj(ccosh(z)) and ccosh is even.
<li> ccosh(NaN + iNaN) returns NaN + iNaN.
</ul>
-<a name="G.6.2.5" href="#G.6.2.5"><h5>G.6.2.5 The csinh functions</h5></a>
+<h5><a name="G.6.2.5" href="#G.6.2.5">G.6.2.5 The csinh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> csinh(conj(z)) = conj(csinh(z)) and csinh is odd.
<li> csinh(NaN + iNaN) returns NaN + iNaN.
</ul>
-<a name="G.6.2.6" href="#G.6.2.6"><h5>G.6.2.6 The ctanh functions</h5></a>
+<h5><a name="G.6.2.6" href="#G.6.2.6">G.6.2.6 The ctanh functions</a></h5>
<p><!--para 1 -->
<ul>
<li> ctanh(conj(z)) = conj(ctanh(z))and ctanh is odd.
<!--page 490 -->
</ul>
-<a name="G.6.3" href="#G.6.3"><h4>G.6.3 Exponential and logarithmic functions</h4></a>
+<h4><a name="G.6.3" href="#G.6.3">G.6.3 Exponential and logarithmic functions</a></h4>
-<a name="G.6.3.1" href="#G.6.3.1"><h5>G.6.3.1 The cexp functions</h5></a>
+<h5><a name="G.6.3.1" href="#G.6.3.1">G.6.3.1 The cexp functions</a></h5>
<p><!--para 1 -->
<ul>
<li> cexp(conj(z)) = conj(cexp(z)).
<li> cexp(NaN + iNaN) returns NaN + iNaN.
</ul>
-<a name="G.6.3.2" href="#G.6.3.2"><h5>G.6.3.2 The clog functions</h5></a>
+<h5><a name="G.6.3.2" href="#G.6.3.2">G.6.3.2 The clog functions</a></h5>
<p><!--para 1 -->
<ul>
<li> clog(conj(z)) = conj(clog(z)).
<li> clog(NaN + iNaN) returns NaN + iNaN.
</ul>
-<a name="G.6.4" href="#G.6.4"><h4>G.6.4 Power and absolute-value functions</h4></a>
+<h4><a name="G.6.4" href="#G.6.4">G.6.4 Power and absolute-value functions</a></h4>
-<a name="G.6.4.1" href="#G.6.4.1"><h5>G.6.4.1 The cpow functions</h5></a>
+<h5><a name="G.6.4.1" href="#G.6.4.1">G.6.4.1 The cpow functions</a></h5>
<p><!--para 1 -->
The cpow functions raise floating-point exceptions if appropriate for the calculation of
the parts of the result, and may raise spurious exceptions.<sup><a href="#note327"><b>327)</b></a></sup>
implementations that treat special cases more carefully.
</small>
-<a name="G.6.4.2" href="#G.6.4.2"><h5>G.6.4.2 The csqrt functions</h5></a>
+<h5><a name="G.6.4.2" href="#G.6.4.2">G.6.4.2 The csqrt functions</a></h5>
<p><!--para 1 -->
<ul>
<li> csqrt(conj(z)) = conj(csqrt(z)).
<!--page 492 -->
</ul>
-<a name="G.7" href="#G.7"><h3>G.7 Type-generic math <tgmath.h></h3></a>
+<h3><a name="G.7" href="#G.7">G.7 Type-generic math <tgmath.h></a></h3>
<p><!--para 1 -->
Type-generic macros that accept complex arguments also accept imaginary arguments. If
an argument is imaginary, the macro expands to an expression whose type is real,
asinh(iy) = i asin(y)
atanh(iy) = i atan(y)</pre>
-<a name="H" href="#H"><h2>Annex H</h2></a>
+<h2><a name="H" href="#H">Annex H</a></h2>
<pre>
(informative)
Language independent arithmetic</pre>
-<a name="H.1" href="#H.1"><h3>H.1 Introduction</h3></a>
+<h3><a name="H.1" href="#H.1">H.1 Introduction</a></h3>
<p><!--para 1 -->
This annex documents the extent to which the C language supports the ISO/IEC 10967-1
standard for language-independent arithmetic (LIA-1). LIA-1 is more general than
IEC 60559 (<a href="#F">annex F</a>) in that it covers integer and diverse floating-point arithmetics.
-<a name="H.2" href="#H.2"><h3>H.2 Types</h3></a>
+<h3><a name="H.2" href="#H.2">H.2 Types</a></h3>
<p><!--para 1 -->
The relevant C arithmetic types meet the requirements of LIA-1 types if an
implementation adds notification of exceptional arithmetic operations and meets the 1
unit in the last place (ULP) accuracy requirement (LIA-1 subclause <a href="#5.2.8">5.2.8</a>).
-<a name="H.2.1" href="#H.2.1"><h4>H.2.1 Boolean type</h4></a>
+<h4><a name="H.2.1" href="#H.2.1">H.2.1 Boolean type</a></h4>
<p><!--para 1 -->
The LIA-1 data type Boolean is implemented by the C data type bool with values of
true and false, all from <a href="#7.16"><stdbool.h></a>.
-<a name="H.2.2" href="#H.2.2"><h4>H.2.2 Integer types</h4></a>
+<h4><a name="H.2.2" href="#H.2.2">H.2.2 Integer types</a></h4>
<p><!--para 1 -->
The signed C integer types int, long int, long long int, and the corresponding
unsigned types are compatible with LIA-1. If an implementation adds support for the
is always 0 for the unsigned types, and is not provided for those types.
<!--page 494 -->
-<a name="H.2.2.1" href="#H.2.2.1"><h5>H.2.2.1 Integer operations</h5></a>
+<h5><a name="H.2.2.1" href="#H.2.2.1">H.2.2.1 Integer operations</a></h5>
<p><!--para 1 -->
The integer operations on integer types are the following:
addI x + y
geqI x >= y
where x and y are expressions of the same integer type.
-<a name="H.2.3" href="#H.2.3"><h4>H.2.3 Floating-point types</h4></a>
+<h4><a name="H.2.3" href="#H.2.3">H.2.3 Floating-point types</a></h4>
<p><!--para 1 -->
The C floating-point types float, double, and long double are compatible with
LIA-1. If an implementation adds support for the LIA-1 exceptional values
operations (see <a href="#F">annex F</a>) along with IEC 60559 status flags and traps has LIA-1
conformant types.
-<a name="H.2.3.1" href="#H.2.3.1"><h5>H.2.3.1 Floating-point parameters</h5></a>
+<h5><a name="H.2.3.1" href="#H.2.3.1">H.2.3.1 Floating-point parameters</a></h5>
<p><!--para 1 -->
The parameters for a floating point data type can be accessed by the following:
r FLT_RADIX
epsilon FLT_EPSILON, DBL_EPSILON, LDBL_EPSILON
rnd_style FLT_ROUNDS
-<a name="H.2.3.2" href="#H.2.3.2"><h5>H.2.3.2 Floating-point operations</h5></a>
+<h5><a name="H.2.3.2" href="#H.2.3.2">H.2.3.2 Floating-point operations</a></h5>
<p><!--para 1 -->
The floating-point operations on floating-point types are the following:
addF x + y
where x and y are expressions of the same floating point type, n is of type int, and li
is of type long int.
-<a name="H.2.3.3" href="#H.2.3.3"><h5>H.2.3.3 Rounding styles</h5></a>
+<h5><a name="H.2.3.3" href="#H.2.3.3">H.2.3.3 Rounding styles</a></h5>
<p><!--para 1 -->
The C Standard requires all floating types to use the same radix and rounding style, so
that only one identifier for each is provided to map to LIA-1.
provided that an implementation extends FLT_ROUNDS to cover the rounding style used
in all relevant LIA-1 operations, not just addition as in C.
-<a name="H.2.4" href="#H.2.4"><h4>H.2.4 Type conversions</h4></a>
+<h4><a name="H.2.4" href="#H.2.4">H.2.4 Type conversions</a></h4>
<p><!--para 1 -->
The LIA-1 type conversions are the following type casts:
cvtI' -> I (int)i, (long int)i, (long long int)i,
implementation uses round-to-nearest.
<!--page 497 -->
-<a name="H.3" href="#H.3"><h3>H.3 Notification</h3></a>
+<h3><a name="H.3" href="#H.3">H.3 Notification</a></h3>
<p><!--para 1 -->
Notification is the process by which a user or program is informed that an exceptional
arithmetic operation has occurred. C's operations are compatible with LIA-1 in that C
allows an implementation to cause a notification to occur when any arithmetic operation
returns an exceptional value as defined in LIA-1 clause 5.
-<a name="H.3.1" href="#H.3.1"><h4>H.3.1 Notification alternatives</h4></a>
+<h4><a name="H.3.1" href="#H.3.1">H.3.1 Notification alternatives</a></h4>
<p><!--para 1 -->
LIA-1 requires at least the following two alternatives for handling of notifications:
setting indicators or trap-and-terminate. LIA-1 allows a third alternative: trap-and-
math library function calls. User-provided signal handlers for SIGFPE allow for trap-
and-resume behavior with the same constraint.
-<a name="H.3.1.1" href="#H.3.1.1"><h5>H.3.1.1 Indicators</h5></a>
+<h5><a name="H.3.1.1" href="#H.3.1.1">H.3.1.1 Indicators</a></h5>
<p><!--para 1 -->
C's <a href="#7.6"><fenv.h></a> status flags are compatible with the LIA-1 indicators.
<p><!--para 2 -->
This documentation makes that distinction because <a href="#7.6"><fenv.h></a> covers only the floating-
point indicators.
-<a name="H.3.1.2" href="#H.3.1.2"><h5>H.3.1.2 Traps</h5></a>
+<h5><a name="H.3.1.2" href="#H.3.1.2">H.3.1.2 Traps</a></h5>
<p><!--para 1 -->
C is compatible with LIA-1's trap requirements for arithmetic operations, but not for
math library functions (which are not permitted to generate any externally visible
resume, at the programmer's option.
<!--page 499 -->
-<a name="I" href="#I"><h2>Annex I</h2></a>
+<h2><a name="I" href="#I">Annex I</a></h2>
<p><!--para 1 -->
<pre>
(informative)
<!--page 501 -->
</ul>
-<a name="J" href="#J"><h2>Annex J</h2></a>
+<h2><a name="J" href="#J">Annex J</a></h2>
<p><!--para 1 -->
<pre>
(informative)
This annex collects some information about portability that appears in this International
Standard.
-<a name="J.1" href="#J.1"><h3>J.1 Unspecified behavior</h3></a>
+<h3><a name="J.1" href="#J.1">J.1 Unspecified behavior</a></h3>
<p><!--para 1 -->
The following are unspecified:
<ul>
<a href="#G.6.2.3">G.6.2.3</a>, <a href="#G.6.2.4">G.6.2.4</a>, <a href="#G.6.2.5">G.6.2.5</a>, <a href="#G.6.2.6">G.6.2.6</a>, <a href="#G.6.3.1">G.6.3.1</a>, <a href="#G.6.4.2">G.6.4.2</a>).
</ul>
-<a name="J.2" href="#J.2"><h3>J.2 Undefined behavior</h3></a>
+<h3><a name="J.2" href="#J.2">J.2 Undefined behavior</a></h3>
<p><!--para 1 -->
The behavior is undefined in the following circumstances:
<ul>
<!--page 517 -->
</ul>
-<a name="J.3" href="#J.3"><h3>J.3 Implementation-defined behavior</h3></a>
+<h3><a name="J.3" href="#J.3">J.3 Implementation-defined behavior</a></h3>
<p><!--para 1 -->
A conforming implementation is required to document its choice of behavior in each of
the areas listed in this subclause. The following are implementation-defined:
-<a name="J.3.1" href="#J.3.1"><h4>J.3.1 Translation</h4></a>
+<h4><a name="J.3.1" href="#J.3.1">J.3.1 Translation</a></h4>
<p><!--para 1 -->
<ul>
<li> How a diagnostic is identified (<a href="#3.10">3.10</a>, <a href="#5.1.1.3">5.1.1.3</a>).
retained or replaced by one space character in translation phase 3 (<a href="#5.1.1.2">5.1.1.2</a>).
</ul>
-<a name="J.3.2" href="#J.3.2"><h4>J.3.2 Environment</h4></a>
+<h4><a name="J.3.2" href="#J.3.2">J.3.2 Environment</a></h4>
<p><!--para 1 -->
<ul>
<li> The mapping between physical source file multibyte characters and the source
<li> The manner of execution of the string by the system function (<a href="#7.20.4.6">7.20.4.6</a>).
</ul>
-<a name="J.3.3" href="#J.3.3"><h4>J.3.3 Identifiers</h4></a>
+<h4><a name="J.3.3" href="#J.3.3">J.3.3 Identifiers</a></h4>
<p><!--para 1 -->
<ul>
<li> Which additional multibyte characters may appear in identifiers and their
<!--page 518 -->
</ul>
-<a name="J.3.4" href="#J.3.4"><h4>J.3.4 Characters</h4></a>
+<h4><a name="J.3.4" href="#J.3.4">J.3.4 Characters</a></h4>
<p><!--para 1 -->
<ul>
<li> The number of bits in a byte (<a href="#3.6">3.6</a>).
represented in the execution character set (<a href="#6.4.5">6.4.5</a>).
</ul>
-<a name="J.3.5" href="#J.3.5"><h4>J.3.5 Integers</h4></a>
+<h4><a name="J.3.5" href="#J.3.5">J.3.5 Integers</a></h4>
<p><!--para 1 -->
<ul>
<li> Any extended integer types that exist in the implementation (<a href="#6.2.5">6.2.5</a>).
<li> The results of some bitwise operations on signed integers (<a href="#6.5">6.5</a>).
</ul>
-<a name="J.3.6" href="#J.3.6"><h4>J.3.6 Floating point</h4></a>
+<h4><a name="J.3.6" href="#J.3.6">J.3.6 Floating point</a></h4>
<p><!--para 1 -->
<ul>
<li> The accuracy of the floating-point operations and of the library functions in
<li> The default state for the FP_CONTRACT pragma (<a href="#7.12.2">7.12.2</a>). *
</ul>
-<a name="J.3.7" href="#J.3.7"><h4>J.3.7 Arrays and pointers</h4></a>
+<h4><a name="J.3.7" href="#J.3.7">J.3.7 Arrays and pointers</a></h4>
<p><!--para 1 -->
<ul>
<li> The result of converting a pointer to an integer or vice versa (<a href="#6.3.2.3">6.3.2.3</a>).
<!--page 520 -->
</ul>
-<a name="J.3.8" href="#J.3.8"><h4>J.3.8 Hints</h4></a>
+<h4><a name="J.3.8" href="#J.3.8">J.3.8 Hints</a></h4>
<p><!--para 1 -->
<ul>
<li> The extent to which suggestions made by using the register storage-class
effective (<a href="#6.7.4">6.7.4</a>).
</ul>
-<a name="J.3.9" href="#J.3.9"><h4>J.3.9 Structures, unions, enumerations, and bit-fields</h4></a>
+<h4><a name="J.3.9" href="#J.3.9">J.3.9 Structures, unions, enumerations, and bit-fields</a></h4>
<p><!--para 1 -->
<ul>
<li> Whether a ''plain'' int bit-field is treated as a signed int bit-field or as an
<li> The integer type compatible with each enumerated type (<a href="#6.7.2.2">6.7.2.2</a>).
</ul>
-<a name="J.3.10" href="#J.3.10"><h4>J.3.10 Qualifiers</h4></a>
+<h4><a name="J.3.10" href="#J.3.10">J.3.10 Qualifiers</a></h4>
<p><!--para 1 -->
<ul>
<li> What constitutes an access to an object that has volatile-qualified type (<a href="#6.7.3">6.7.3</a>).
</ul>
-<a name="J.3.11" href="#J.3.11"><h4>J.3.11 Preprocessing directives</h4></a>
+<h4><a name="J.3.11" href="#J.3.11">J.3.11 Preprocessing directives</a></h4>
<p><!--para 1 -->
<ul>
<li> The locations within #pragma directives where header name preprocessing tokens
time of translation are not available (<a href="#6.10.8">6.10.8</a>).
</ul>
-<a name="J.3.12" href="#J.3.12"><h4>J.3.12 Library functions</h4></a>
+<h4><a name="J.3.12" href="#J.3.12">J.3.12 Library functions</a></h4>
<p><!--para 1 -->
<ul>
<li> Any library facilities available to a freestanding program, other than the minimal set
IEC 60559 conformant implementation, unless explicitly specified otherwise (<a href="#F.9">F.9</a>).
</ul>
-<a name="J.3.13" href="#J.3.13"><h4>J.3.13 Architecture</h4></a>
+<h4><a name="J.3.13" href="#J.3.13">J.3.13 Architecture</a></h4>
<p><!--para 1 -->
<ul>
<li> The values or expressions assigned to the macros specified in the headers
<!--page 524 -->
</ul>
-<a name="J.4" href="#J.4"><h3>J.4 Locale-specific behavior</h3></a>
+<h3><a name="J.4" href="#J.4">J.4 Locale-specific behavior</a></h3>
<p><!--para 1 -->
The following characteristics of a hosted environment are locale-specific and are required
to be documented by the implementation:
<!--page 525 -->
</ul>
-<a name="J.5" href="#J.5"><h3>J.5 Common extensions</h3></a>
+<h3><a name="J.5" href="#J.5">J.5 Common extensions</a></h3>
<p><!--para 1 -->
The following extensions are widely used in many systems, but are not portable to all
implementations. The inclusion of any extension that may cause a strictly conforming
extensions are new keywords, extra library functions declared in standard headers, or
predefined macros with names that do not begin with an underscore.
-<a name="J.5.1" href="#J.5.1"><h4>J.5.1 Environment arguments</h4></a>
+<h4><a name="J.5.1" href="#J.5.1">J.5.1 Environment arguments</a></h4>
<p><!--para 1 -->
In a hosted environment, the main function receives a third argument, char *envp[],
that points to a null-terminated array of pointers to char, each of which points to a string
that provides information about the environment for this execution of the program
(<a href="#5.1.2.2.1">5.1.2.2.1</a>).
-<a name="J.5.2" href="#J.5.2"><h4>J.5.2 Specialized identifiers</h4></a>
+<h4><a name="J.5.2" href="#J.5.2">J.5.2 Specialized identifiers</a></h4>
<p><!--para 1 -->
Characters other than the underscore _, letters, and digits, that are not part of the basic
source character set (such as the dollar sign $, or characters in national character sets)
may appear in an identifier (<a href="#6.4.2">6.4.2</a>).
-<a name="J.5.3" href="#J.5.3"><h4>J.5.3 Lengths and cases of identifiers</h4></a>
+<h4><a name="J.5.3" href="#J.5.3">J.5.3 Lengths and cases of identifiers</a></h4>
<p><!--para 1 -->
All characters in identifiers (with or without external linkage) are significant (<a href="#6.4.2">6.4.2</a>).
-<a name="J.5.4" href="#J.5.4"><h4>J.5.4 Scopes of identifiers</h4></a>
+<h4><a name="J.5.4" href="#J.5.4">J.5.4 Scopes of identifiers</a></h4>
<p><!--para 1 -->
A function identifier, or the identifier of an object the declaration of which contains the
keyword extern, has file scope (<a href="#6.2.1">6.2.1</a>).
-<a name="J.5.5" href="#J.5.5"><h4>J.5.5 Writable string literals</h4></a>
+<h4><a name="J.5.5" href="#J.5.5">J.5.5 Writable string literals</a></h4>
<p><!--para 1 -->
String literals are modifiable (in which case, identical string literals should denote distinct
objects) (<a href="#6.4.5">6.4.5</a>).
-<a name="J.5.6" href="#J.5.6"><h4>J.5.6 Other arithmetic types</h4></a>
+<h4><a name="J.5.6" href="#J.5.6">J.5.6 Other arithmetic types</a></h4>
<p><!--para 1 -->
Additional arithmetic types, such as __int128 or double double, and their
appropriate conversions are defined (<a href="#6.2.5">6.2.5</a>, <a href="#6.3.1">6.3.1</a>). Additional floating types may have
other floating types, and may be used to define float_t or double_t.
<!--page 526 -->
-<a name="J.5.7" href="#J.5.7"><h4>J.5.7 Function pointer casts</h4></a>
+<h4><a name="J.5.7" href="#J.5.7">J.5.7 Function pointer casts</a></h4>
<p><!--para 1 -->
A pointer to an object or to void may be cast to a pointer to a function, allowing data to
be invoked as a function (<a href="#6.5.4">6.5.4</a>).
A pointer to a function may be cast to a pointer to an object or to void, allowing a
function to be inspected or modified (for example, by a debugger) (<a href="#6.5.4">6.5.4</a>).
-<a name="J.5.8" href="#J.5.8"><h4>J.5.8 Extended bit-field types</h4></a>
+<h4><a name="J.5.8" href="#J.5.8">J.5.8 Extended bit-field types</a></h4>
<p><!--para 1 -->
A bit-field may be declared with a type other than _Bool, unsigned int, or
signed int, with an appropriate maximum width (<a href="#6.7.2.1">6.7.2.1</a>).
-<a name="J.5.9" href="#J.5.9"><h4>J.5.9 The fortran keyword</h4></a>
+<h4><a name="J.5.9" href="#J.5.9">J.5.9 The fortran keyword</a></h4>
<p><!--para 1 -->
The fortran function specifier may be used in a function declaration to indicate that
calls suitable for FORTRAN should be generated, or that a different representation for the
external name is to be generated (<a href="#6.7.4">6.7.4</a>).
-<a name="J.5.10" href="#J.5.10"><h4>J.5.10 The asm keyword</h4></a>
+<h4><a name="J.5.10" href="#J.5.10">J.5.10 The asm keyword</a></h4>
<p><!--para 1 -->
The asm keyword may be used to insert assembly language directly into the translator
output (<a href="#6.8">6.8</a>). The most common implementation is via a statement of the form:
<pre>
asm ( character-string-literal );</pre>
-<a name="J.5.11" href="#J.5.11"><h4>J.5.11 Multiple external definitions</h4></a>
+<h4><a name="J.5.11" href="#J.5.11">J.5.11 Multiple external definitions</a></h4>
<p><!--para 1 -->
There may be more than one external definition for the identifier of an object, with or
without the explicit use of the keyword extern; if the definitions disagree, or more than
one is initialized, the behavior is undefined (<a href="#6.9.2">6.9.2</a>).
-<a name="J.5.12" href="#J.5.12"><h4>J.5.12 Predefined macro names</h4></a>
+<h4><a name="J.5.12" href="#J.5.12">J.5.12 Predefined macro names</a></h4>
<p><!--para 1 -->
Macro names that do not begin with an underscore, describing the translation and
execution environments, are defined by the implementation before translation begins
(<a href="#6.10.8">6.10.8</a>).
-<a name="J.5.13" href="#J.5.13"><h4>J.5.13 Floating-point status flags</h4></a>
+<h4><a name="J.5.13" href="#J.5.13">J.5.13 Floating-point status flags</a></h4>
<p><!--para 1 -->
If any floating-point status flags are set on normal termination after all calls to functions
registered by the atexit function have been made (see <a href="#7.20.4.3">7.20.4.3</a>), the implementation
writes some diagnostics indicating the fact to the stderr stream, if it is still open,
<!--page 527 -->
-<a name="J.5.14" href="#J.5.14"><h4>J.5.14 Extra arguments for signal handlers</h4></a>
+<h4><a name="J.5.14" href="#J.5.14">J.5.14 Extra arguments for signal handlers</a></h4>
<p><!--para 1 -->
Handlers for specific signals are called with extra arguments in addition to the signal
number (<a href="#7.14.1.1">7.14.1.1</a>).
-<a name="J.5.15" href="#J.5.15"><h4>J.5.15 Additional stream types and file-opening modes</h4></a>
+<h4><a name="J.5.15" href="#J.5.15">J.5.15 Additional stream types and file-opening modes</a></h4>
<p><!--para 1 -->
Additional mappings from files to streams are supported (<a href="#7.19.2">7.19.2</a>).
<p><!--para 2 -->
Additional file-opening modes may be specified by characters appended to the mode
argument of the fopen function (<a href="#7.19.5.3">7.19.5.3</a>).
-<a name="J.5.16" href="#J.5.16"><h4>J.5.16 Defined file position indicator</h4></a>
+<h4><a name="J.5.16" href="#J.5.16">J.5.16 Defined file position indicator</a></h4>
<p><!--para 1 -->
The file position indicator is decremented by each successful call to the ungetc or
ungetwc function for a text stream, except if its value was zero before a call (<a href="#7.19.7.11">7.19.7.11</a>,
<a href="#7.24.3.10">7.24.3.10</a>).
-<a name="J.5.17" href="#J.5.17"><h4>J.5.17 Math error reporting</h4></a>
+<h4><a name="J.5.17" href="#J.5.17">J.5.17 Math error reporting</a></h4>
<p><!--para 1 -->
Functions declared in <a href="#7.3"><complex.h></a> and <a href="#7.12"><math.h></a> raise SIGFPE to report errors
instead of, or in addition to, setting errno or raising floating-point exceptions (<a href="#7.3">7.3</a>,
<a href="#7.12">7.12</a>).
<!--page 528 -->
-<a name="Bibliography" href="#Bibliography"><h2>Bibliography</h2></a>
+<h2><a name="Bibliography" href="#Bibliography">Bibliography</a></h2>
<ol>
<li> ''The C Reference Manual'' by Dennis M. Ritchie, a version of which was
published in The C Programming Language by Brian W. Kernighan and Dennis
<!--page 531 -->
</ol>
-<a name="Index" href="#Index"><h2>Index</h2></a>
+<h2><a name="Index" href="#Index">Index</a></h2>
<pre>
??? x ???, <a href="#3.18">3.18</a> , (comma punctuator), <a href="#6.5.2">6.5.2</a>, <a href="#6.7">6.7</a>, <a href="#6.7.2.1">6.7.2.1</a>, <a href="#6.7.2.2">6.7.2.2</a>,
<a href="#6.7.2.3">6.7.2.3</a>, <a href="#6.7.8">6.7.8</a>