From Jason Turner

[support.c.headers.general]

Diff to HTML by rtfpessoa

tmp/tmpanj0pnvm/{from.md → to.md} RENAMED
@@ -2,31 +2,31 @@
2
 
3
  For compatibility with the C standard library, the C++ standard library
4
  provides the *C headers* shown in [[c.headers]]. The intended use of
5
  these headers is for interoperability only. It is possible that C++
6
  source files need to include one of these headers in order to be valid
7
- ISO C. Source files that are not intended to also be valid ISO C should
8
- not use any of the C headers.
9
 
10
  [*Note 1*: The C headers either have no effect, such as `<stdbool.h>`
11
  and `<stdalign.h>`, or otherwise the corresponding header of the form
12
  `<cname>` provides the same facilities and assuredly defines them in
13
  namespace `std`. — *end note*]
14
 
15
  [*Example 1*:
16
 
17
- The following source file is both valid C++ and valid ISO C. Viewed as
18
- C++, it declares a function with C language linkage; viewed as C it
19
- simply declares a function (and provides a prototype).
20
 
21
  ``` cpp
22
- #include <stdbool.h> // for bool in C, no effect in C++{}
23
  #include <stddef.h> // for size_t
24
 
25
  #ifdef __cplusplus // see [cpp.predefined]
26
  extern "C" // see [dcl.link]
27
  #endif
28
- void f(bool b[], size_t n);
29
  ```
30
 
31
  — *end example*]
32
 
 
2
 
3
  For compatibility with the C standard library, the C++ standard library
4
  provides the *C headers* shown in [[c.headers]]. The intended use of
5
  these headers is for interoperability only. It is possible that C++
6
  source files need to include one of these headers in order to be valid
7
+ C. Source files that are not intended to also be valid C should not use
8
+ any of the C headers.
9
 
10
  [*Note 1*: The C headers either have no effect, such as `<stdbool.h>`
11
  and `<stdalign.h>`, or otherwise the corresponding header of the form
12
  `<cname>` provides the same facilities and assuredly defines them in
13
  namespace `std`. — *end note*]
14
 
15
  [*Example 1*:
16
 
17
+ The following source file is both valid C++ and valid C. Viewed as C++,
18
+ it declares a function with C language linkage; viewed as C it simply
19
+ declares a function (and provides a prototype).
20
 
21
  ``` cpp
22
+ #include <uchar.h> // for char8_t in C, not necessary in C++{}
23
  #include <stddef.h> // for size_t
24
 
25
  #ifdef __cplusplus // see [cpp.predefined]
26
  extern "C" // see [dcl.link]
27
  #endif
28
+ void f(char8_t s[], size_t n);
29
  ```
30
 
31
  — *end example*]
32