|
904 | 904 | \pnum
|
905 | 905 | An implementation may use any technique that provides equivalent observable behavior.
|
906 | 906 |
|
| 907 | +\rSec3[freestanding.entity]{Freestanding entities} |
| 908 | + |
| 909 | +\pnum |
| 910 | +A \defnadj{freestanding}{entity} is a declaration or macro definition |
| 911 | +that is present in a freestanding implementation and a hosted implementation. |
| 912 | + |
| 913 | +\pnum |
| 914 | +Unless otherwise specified, |
| 915 | +the requirements on freestanding entities on a freestanding implementation |
| 916 | +are the same as the corresponding requirements in a hosted implementation. |
| 917 | + |
| 918 | +\pnum |
| 919 | +In a header synopsis, entities followed with a comment |
| 920 | +that includes \textit{freestanding} are freestanding entities. |
| 921 | +\begin{example} |
| 922 | +\begin{codeblock} |
| 923 | +#define NULL see below // freestanding |
| 924 | +\end{codeblock} |
| 925 | +\end{example} |
| 926 | + |
| 927 | +\pnum |
| 928 | +If a header synopsis begins with a comment |
| 929 | +that includes \textit{all freestanding}, |
| 930 | +then all of the declarations and macro definitions in the header synopsis |
| 931 | +are freestanding entities. |
| 932 | +\begin{example} |
| 933 | +\begin{codeblock} |
| 934 | +// all freestanding |
| 935 | +namespace std { |
| 936 | +\end{codeblock} |
| 937 | +\end{example} |
| 938 | + |
| 939 | +\pnum |
| 940 | +Deduction guides for freestanding entity class templates are freestanding entities. |
| 941 | + |
| 942 | +\pnum |
| 943 | +Enclosing namespaces of freestanding entities are freestanding entities. |
| 944 | + |
| 945 | +\pnum |
| 946 | +Friends of freestanding entities are freestanding entities. |
| 947 | + |
| 948 | +\pnum |
| 949 | +Entities denoted by freestanding entity \grammarterm{typedef-names} and |
| 950 | +freestanding entity alias templates are freestanding entities. |
| 951 | + |
907 | 952 | \rSec1[requirements]{Library-wide requirements}
|
908 | 953 |
|
909 | 954 | \rSec2[requirements.general]{General}
|
|
1342 | 1387 | \ref{concepts} & Concepts library & \tcode{<concepts>} \\ \rowsep
|
1343 | 1388 | \ref{type.traits} & Type traits & \tcode{<type_traits>} \\ \rowsep
|
1344 | 1389 | \ref{bit} & Bit manipulation & \tcode{<bit>} \\ \rowsep
|
1345 |
| -\ref{atomics} & Atomics & \tcode{<atomic>} \\ |
| 1390 | +\ref{atomics} & Atomics & \tcode{<atomic>} \\ \rowsep |
| 1391 | +\ref{utility} & Utility components & \tcode{<utility>} \\ \rowsep |
| 1392 | +\ref{tuple} & Tuples & \tcode{<tuple>} \\ \rowsep |
| 1393 | +\ref{memory} & Memory & \tcode{<memory>} \\ \rowsep |
| 1394 | +\ref{function.objects} & Function objects & \tcode{<functional>} \\ \rowsep |
| 1395 | +\ref{ratio} & Compile-time rational arithmetic & \tcode{<ratio>} \\ \rowsep |
| 1396 | +\ref{iterators} & Iterators library & \tcode{<iterator>} \\ \rowsep |
| 1397 | +\ref{ranges} & Ranges library & \tcode{<ranges>} \\ |
1346 | 1398 | \end{libsumtab}
|
1347 | 1399 |
|
1348 | 1400 | \pnum
|
1349 |
| -The supplied version of the header \libheaderref{cstdlib} |
1350 |
| -shall declare at least the functions |
1351 |
| -\indexlibraryglobal{abort}% |
1352 |
| -\tcode{abort}, |
1353 |
| -\indexlibraryglobal{atexit}% |
1354 |
| -\tcode{atexit}, |
1355 |
| -\indexlibraryglobal{at_quick_exit}% |
1356 |
| -\tcode{at_quick_exit}, |
1357 |
| -\indexlibraryglobal{exit}% |
1358 |
| -\tcode{exit}, |
1359 |
| -and |
1360 |
| -\indexlibraryglobal{quick_exit}% |
1361 |
| -\tcode{quick_exit}\iref{support.start.term}. |
1362 |
| -\indextext{implementation!hosted}% |
1363 |
| -The supplied version of the header \libheaderrefx{atomic}{atomics.syn} |
1364 |
| -shall meet the same requirements as for a hosted implementation |
1365 |
| -except that support for |
1366 |
| -always lock-free integral atomic types\iref{atomics.lockfree} |
1367 |
| -is \impldef{support for always lock-free integral atomic types in |
1368 |
| -freestanding environments}, and |
1369 |
| -whether or not the type aliases \tcode{atomic_signed_lock_free} and |
1370 |
| -\tcode{atomic_unsigned_lock_free} are defined\iref{atomics.alias} |
1371 |
| -is \impldef{type aliases \tcode{atomic_signed_lock_free} and |
1372 |
| -\tcode{atomic_unsigned_lock_free} in freestanding environments}. |
1373 |
| -The other headers listed in this table |
1374 |
| -shall meet the same requirements as for a hosted implementation. |
| 1401 | +For each of the headers listed in \tref{headers.cpp.fs}, |
| 1402 | +a freestanding implementation provides at least |
| 1403 | +the freestanding entities\iref{freestanding.entity} declared in the header. |
1375 | 1404 | \indextext{implementation!freestanding|)}%
|
1376 | 1405 |
|
| 1406 | +\pnum |
| 1407 | +\begin{note} |
| 1408 | +Throwing a standard library provided exception |
| 1409 | +is not observably different from \tcode{terminate()} |
| 1410 | +if the implementation does not |
| 1411 | +unwind the stack during exception handling\iref{except.handle} and |
| 1412 | +the user's program contains no catch blocks. |
| 1413 | +\end{note} |
| 1414 | + |
1377 | 1415 | \rSec2[using]{Using the library}
|
1378 | 1416 |
|
1379 | 1417 | \rSec3[using.overview]{Overview}
|
|
0 commit comments