Skip to content

Repo sync for protected CLA branch #4238

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Oct 24, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 1 addition & 1 deletion docs/c-runtime-library/ansi-c-compliance.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ The naming convention for all Microsoft-specific identifiers in the run-time sys

The names of Microsoft-specific functions and global variables begin with a single underscore. These names can be overridden only locally, within the scope of your code. For example, when you include Microsoft run-time header files, you can still locally override the Microsoft-specific function named `_open` by declaring a local variable of the same name. However, you can't use this name for your own global function or global variable.

The names of Microsoft-specific macros and manifest constants begin with two underscores, or with a single leading underscore immediately followed by an uppercase letter. The scope of such identifiers is absolute. For example, you can't use the Microsoft-specific identifier **_UPPER** for this reason.
The names of Microsoft-specific macros and manifest constants begin with two underscores, or with a single leading underscore immediately followed by an uppercase letter. The scope of such identifiers is absolute. For example, you can't use the Microsoft-specific identifier `_UPPER` for this reason.

## See also

Expand Down
2 changes: 1 addition & 1 deletion docs/c-runtime-library/argument-access.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ms.assetid: 7046ae34-a0ec-44f0-815d-3209492a3e19
---
# Argument access

The **va_arg**, **va_end**, and **va_start** macros provide access to function arguments when the number of arguments is variable. These macros are defined in \<stdarg.h> for ANSI/ISO C compatibility and in \<varargs.h> for compatibility with UNIX System V.
The `va_arg`, `va_end`, and `va_start` macros provide access to function arguments when the number of arguments is variable. These macros are defined in \<stdarg.h> for ANSI/ISO C compatibility and in \<varargs.h> for compatibility with UNIX System V.

## Argument-access macros

Expand Down
2 changes: 1 addition & 1 deletion docs/c-runtime-library/buffer-manipulation.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Use these routines to work with areas of memory on a byte-by-byte basis.
|[`memset`, `wmemset`](./reference/memset-wmemset.md)|Use given character to initialize specified number of bytes in the buffer|
|[`_swab`](./reference/swab.md)|Swap bytes of data and store them at specified location|

When the source and target areas overlap, only **memmove** is guaranteed to copy the full source properly.
When the source and target areas overlap, only `memmove` is guaranteed to copy the full source properly.

## See also

Expand Down
4 changes: 2 additions & 2 deletions docs/c-runtime-library/cgets-cgetws.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ Storage location for data.

## Return value

`_cgets` and `_cgetws` return a pointer to the start of the string, at `buffer[2]`. If `buffer` is **NULL**, these functions invoke the invalid parameter handler, as described in [Parameter validation](./parameter-validation.md). If execution is allowed to continue, they return **NULL** and set `errno` to `EINVAL`.
`_cgets` and `_cgetws` return a pointer to the start of the string, at `buffer[2]`. If `buffer` is `NULL`, these functions invoke the invalid parameter handler, as described in [Parameter validation](./parameter-validation.md). If execution is allowed to continue, they return `NULL` and set `errno` to `EINVAL`.

## Remarks

Expand All @@ -60,7 +60,7 @@ By default, this function's global state is scoped to the application. To change

### Generic-text routine mappings

|Tchar.h routine|_UNICODE and _MBCS not defined|_MBCS defined|_UNICODE defined|
|Tchar.h routine|`_UNICODE` and `_MBCS` not defined|`_MBCS` defined|`_UNICODE` defined|
|---------------------|--------------------------------------|--------------------|-----------------------|
|`_cgetts`|`_cgets`|`_cgets`|`_cgetws`|

Expand Down
4 changes: 2 additions & 2 deletions docs/c-runtime-library/character-classification.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ms.assetid: 3b6c8f0b-9701-407a-b384-9086698773f5

Each of these routines tests a specified single-byte character, wide character, or multibyte character for satisfaction of a condition. (By definition, the ASCII character set between 0 and 127 are a subset of all multibyte-character sets. For example, Japanese katakana includes both ASCII and non-ASCII characters.)

The test conditions are affected by the setting of the **LC_CTYPE** category setting of the locale. For more information, see [`setlocale`](./reference/setlocale-wsetlocale.md). The versions of these functions without the **_l** suffix use the current locale for this locale-dependent behavior; the versions with the **_l** suffix are identical except that they use the locale parameter passed in instead.
The test conditions are affected by the setting of the `LC_CTYPE` category setting of the locale. For more information, see [`setlocale`](./reference/setlocale-wsetlocale.md). The versions of these functions without the `_l` suffix use the current locale for this locale-dependent behavior; the versions with the `_l` suffix are identical except that they use the locale parameter passed in instead.

Generally these routines execute faster than tests you might write and should be favored over. For example, the following code executes slower than a call to `isalpha(c)`:

Expand Down Expand Up @@ -47,7 +47,7 @@ if ((c >= 'A') && (c <= 'Z')) || ((c >= 'a') && (c <= 'z'))
|[`isupper`, `iswupper`](./reference/isupper-isupper-l-iswupper-iswupper-l.md), [`_ismbclower`, `_ismbclower_l`, `_ismbcupper`, `_ismbcupper_l`](./reference/ismbclower-ismbclower-l-ismbcupper-ismbcupper-l.md)|Uppercase|
|[`_isctype`, `iswctype`, `_isctype_l`, `_iswctype_l`](./reference/isctype-iswctype-isctype-l-iswctype-l.md)|Property specified by *`desc`* argument|
|[`isxdigit`, `iswxdigit`, `_isxdigit_l`, `_iswxdigit_l`](./reference/isxdigit-iswxdigit-isxdigit-l-iswxdigit-l.md)|Hexadecimal digit|
|[`_mbclen`, `mblen`, `_mblen_l`](./reference/mbclen-mblen-mblen-l.md)|Return length of valid multibyte character; result depends on **LC_CTYPE** category setting of current locale|
|[`_mbclen`, `mblen`, `_mblen_l`](./reference/mbclen-mblen-mblen-l.md)|Return length of valid multibyte character; result depends on `LC_CTYPE` category setting of current locale|

## See also

Expand Down
2 changes: 1 addition & 1 deletion docs/c-runtime-library/code-pages.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ The Microsoft runtime library uses the following types of code pages:

- Multibyte code page. The behavior of most of the multibyte-character routines in the run-time library depends on the current multibyte code page setting. By default, these routines use the system-default ANSI code page. At run-time you can query and change the multibyte code page with [`_getmbcp`](./reference/getmbcp.md) and [`_setmbcp`](./reference/setmbcp.md), respectively.

- The "C" locale is defined by ANSI to correspond to the locale in which C programs have traditionally executed. The code page for the "C" locale ("C" code page) corresponds to the ASCII character set. For example, in the "C" locale, **islower** returns true for the values 0x61 - 0x7A only. In another locale, **islower** may return `true` for these and other values, as defined by that locale.
- The "C" locale is defined by ANSI to correspond to the locale in which C programs have traditionally executed. The code page for the "C" locale ("C" code page) corresponds to the ASCII character set. For example, in the "C" locale, `islower` returns true for the values 0x61 - 0x7A only. In another locale, `islower` may return `true` for these and other values, as defined by that locale.

## See also

Expand Down
2 changes: 1 addition & 1 deletion docs/c-runtime-library/crtdbg-map-alloc.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ms.assetid: 435242b8-caea-4063-b765-4a608200312b
---
# `_CRTDBG_MAP_ALLOC`

When the **_CRTDBG_MAP_ALLOC** flag is defined in the debug version of an application, the base versions of the heap functions are directly mapped to their debug versions. The flag is used in Crtdbg.h to do the mapping. This flag is only available when the [`_DEBUG`](./debug.md) flag has been defined in the application.
When the `_CRTDBG_MAP_ALLOC` flag is defined in the debug version of an application, the base versions of the heap functions are directly mapped to their debug versions. The flag is used in Crtdbg.h to do the mapping. This flag is only available when the [`_DEBUG`](./debug.md) flag has been defined in the application.

For more information about using the debug version versus the base version of a heap function, see [Using the debug version versus the base version](/visualstudio/debugger/debug-versions-of-heap-allocation-functions).

Expand Down
2 changes: 1 addition & 1 deletion docs/c-runtime-library/crtdbgflag.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ ms.assetid: 9e7adb47-8ab9-4e19-81d5-e2f237979973
---
# `_crtDbgFlag`

The **_crtDbgFlag** flag consists of five bit-fields that control how memory allocations on the debug version of the heap are tracked, verified, reported, and dumped. The bit fields of the flag are set using the [`_CrtSetDbgFlag`](./reference/crtsetdbgflag.md) function. This flag and its bit fields are declared in Crtdbg.h. This flag is only available when the [`_DEBUG`](./debug.md) flag has been defined in the application.
The **`_crtDbgFlag`** flag consists of five bit-fields that control how memory allocations on the debug version of the heap are tracked, verified, reported, and dumped. The bit fields of the flag are set using the [`_CrtSetDbgFlag`](./reference/crtsetdbgflag.md) function. This flag and its bit fields are declared in Crtdbg.h. This flag is only available when the [`_DEBUG`](./debug.md) flag has been defined in the application.

For more information about using this flag along with other debug functions, see [Heap state reporting functions](/visualstudio/debugger/crt-debug-heap-details).

Expand Down
150 changes: 75 additions & 75 deletions docs/c-runtime-library/data-type-constants.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,42 +22,42 @@ These constants give the ranges for the integral data types. To use these consta

|Constant|Value|Description|
|--------------|-----------|-------------|
|**`CHAR_BIT`**|8|Number of bits in a **`char`**|
|**`SCHAR_MIN`**|(-128)|Minimum **`signed char`** value|
|**`SCHAR_MAX`**|127|Maximum **`signed char`** value|
|**`UCHAR_MAX`**|255 (0xff)|Maximum **`unsigned char`** value|
|**`CHAR_MIN`**|(-128) (0 if **`/J`** option used)|Minimum **`char`** value|
|**`CHAR_MAX`**|127 (255 if **`/J`** option used)|Maximum **`char`** value|
|**`MB_LEN_MAX`**|5|Maximum number of bytes in multibyte **`char`**|
|**`SHRT_MIN`**|-32768|Minimum **`signed short`** value|
|**`SHRT_MAX`**|32767|Maximum **`signed short`** value|
|**`USHRT_MAX`**|65535 (0xffff)|Maximum **`unsigned short`** value|
|**`INT_MIN`**|(-2147483647 - 1)|Minimum **`signed int`** value|
|**`INT_MAX`**|2147483647|Maximum **`signed int`** value|
|**`UINT_MAX`**|4294967295 (0xffffffff)|Maximum **`unsigned int`** value|
|**`LONG_MIN`**|(-2147483647L - 1)|Minimum **`signed long`** value|
|**`LONG_MAX`**|2147483647L|Maximum **`signed long`** value|
|**`ULONG_MAX`**|4294967295UL (0xfffffffful)|Maximum **`unsigned long`** value|
|**`LLONG_MIN`**|(-9223372036854775807LL - 1)|Minimum **`signed long long`** or **`__int64`** value|
|**`LLONG_MAX`**|9223372036854775807LL|Maximum **`signed long long`** or **`__int64`** value|
|**`ULLONG_MAX`**|0xffffffffffffffffull|Maximum **`unsigned long long`** value|
|**`_I8_MIN`**|(-127i8 - 1)|Minimum signed 8-bit value|
|**`_I8_MAX`**|127i8|Maximum signed 8-bit value|
|**`_UI8_MAX`**|0xffui8|Maximum unsigned 8-bit value|
|**`_I16_MIN`**|(-32767i16 - 1)|Minimum signed 16-bit value|
|**`_I16_MAX`**|32767i16|Maximum signed 16-bit value|
|**`_UI16_MAX`**|0xffffui16|Maximum unsigned 16-bit value|
|**`_I32_MIN`**|(-2147483647i32 - 1)|Minimum signed 32-bit value|
|**`_I32_MAX`**|2147483647i32|Maximum signed 32-bit value|
|**`_UI32_MAX`**|0xffffffffui32|Maximum unsigned 32-bit value|
|**`_I64_MIN`**|(-9223372036854775807 - 1)|Minimum signed 64-bit value|
|**`_I64_MAX`**|9223372036854775807|Maximum signed 64-bit value|
|**`_UI64_MAX`**|0xffffffffffffffffui64|Maximum unsigned 64-bit value|
|**`_I128_MIN`**|(-170141183460469231731687303715884105727i128 - 1)|Minimum signed 128-bit value|
|**`_I128_MAX`**|170141183460469231731687303715884105727i128|Maximum signed 128-bit value|
|**`_UI128_MAX`**|0xffffffffffffffffffffffffffffffffui128|Maximum unsigned 128-bit value|
|**`SIZE_MAX`**|same as **`_UI64_MAX`** if **`_WIN64`** is defined, or **`UINT_MAX`**|Maximum native integer size|
|**`RSIZE_MAX`**|same as (**`SIZE_MAX`** >> 1)|Maximum secure library integer size|
|`CHAR_BIT`|8|Number of bits in a **`char`**|
|`SCHAR_MIN`|(-128)|Minimum **`signed char`** value|
|`SCHAR_MAX`|127|Maximum **`signed char`** value|
|`UCHAR_MAX`|255 (0xff)|Maximum **`unsigned char`** value|
|`CHAR_MIN`|(-128) (0 if **`/J`** option used)|Minimum **`char`** value|
|`CHAR_MAX`|127 (255 if **`/J`** option used)|Maximum **`char`** value|
|`MB_LEN_MAX`|5|Maximum number of bytes in multibyte **`char`**|
|`SHRT_MIN`|-32768|Minimum **`signed short`** value|
|`SHRT_MAX`|32767|Maximum **`signed short`** value|
|`USHRT_MAX`|65535 (0xffff)|Maximum **`unsigned short`** value|
|`INT_MIN`|(-2147483647 - 1)|Minimum **`signed int`** value|
|`INT_MAX`|2147483647|Maximum **`signed int`** value|
|`UINT_MAX`|4294967295 (0xffffffff)|Maximum **`unsigned int`** value|
|`LONG_MIN`|(-2147483647L - 1)|Minimum **`signed long`** value|
|`LONG_MAX`|2147483647L|Maximum **`signed long`** value|
|`ULONG_MAX`|4294967295UL (0xfffffffful)|Maximum **`unsigned long`** value|
|`LLONG_MIN`|(-9223372036854775807LL - 1)|Minimum **`signed long long`** or **`__int64`** value|
|`LLONG_MAX`|9223372036854775807LL|Maximum **`signed long long`** or **`__int64`** value|
|`ULLONG_MAX`|0xffffffffffffffffull|Maximum **`unsigned long long`** value|
|`_I8_MIN`|(-127i8 - 1)|Minimum signed 8-bit value|
|`_I8_MAX`|127i8|Maximum signed 8-bit value|
|`_UI8_MAX`|0xffui8|Maximum unsigned 8-bit value|
|`_I16_MIN`|(-32767i16 - 1)|Minimum signed 16-bit value|
|`_I16_MAX`|32767i16|Maximum signed 16-bit value|
|`_UI16_MAX`|0xffffui16|Maximum unsigned 16-bit value|
|`_I32_MIN`|(-2147483647i32 - 1)|Minimum signed 32-bit value|
|`_I32_MAX`|2147483647i32|Maximum signed 32-bit value|
|`_UI32_MAX`|0xffffffffui32|Maximum unsigned 32-bit value|
|`_I64_MIN`|(-9223372036854775807 - 1)|Minimum signed 64-bit value|
|`_I64_MAX`|9223372036854775807|Maximum signed 64-bit value|
|`_UI64_MAX`|0xffffffffffffffffui64|Maximum unsigned 64-bit value|
|`_I128_MIN`|(-170141183460469231731687303715884105727i128 - 1)|Minimum signed 128-bit value|
|`_I128_MAX`|170141183460469231731687303715884105727i128|Maximum signed 128-bit value|
|`_UI128_MAX`|0xffffffffffffffffffffffffffffffffui128|Maximum unsigned 128-bit value|
|`SIZE_MAX`|same as `_UI64_MAX` if `_WIN64` is defined, or `UINT_MAX`|Maximum native integer size|
|`RSIZE_MAX`|same as (`SIZE_MAX` >> 1)|Maximum secure library integer size|

## Floating-point type constants

Expand All @@ -69,45 +69,45 @@ The following constants give the range and other characteristics of the **`long

|Constant|Value|Description|
|--------------|-----------|-----------------|
|**`DBL_DECIMAL_DIG`**|17|# of decimal digits of rounding precision|
|**`DBL_DIG`**|15|# of decimal digits of precision|
|**`DBL_EPSILON`**|2.2204460492503131e-016|Smallest such that 1.0 + **`DBL_EPSILON`** != 1.0|
|**`DBL_HAS_SUBNORM`**|1|Type supports subnormal (denormal) numbers|
|**`DBL_MANT_DIG`**|53|# of bits in significand (mantissa)|
|**`DBL_MAX`**|1.7976931348623158e+308|Maximum value|
|**`DBL_MAX_10_EXP`**|308|Maximum decimal exponent|
|**`DBL_MAX_EXP`**|1024|Maximum binary exponent|
|**`DBL_MIN`**|2.2250738585072014e-308|Minimum normalized positive value|
|**`DBL_MIN_10_EXP`**|(-307)|Minimum decimal exponent|
|**`DBL_MIN_EXP`**|(-1021)|Minimum binary exponent|
|**`_DBL_RADIX`**|2|Exponent radix|
|**`DBL_TRUE_MIN`**|4.9406564584124654e-324|Minimum positive subnormal value|
|**`FLT_DECIMAL_DIG`**|9|Number of decimal digits of rounding precision|
|**`FLT_DIG`**|6|Number of decimal digits of precision|
|**`FLT_EPSILON`**|1.192092896e-07F|Smallest such that 1.0 + **`FLT_EPSILON`** != 1.0|
|**`FLT_HAS_SUBNORM`**|1|Type supports subnormal (denormal) numbers|
|**`FLT_MANT_DIG`**|24|Number of bits in significand (mantissa)|
|**`FLT_MAX`**|3.402823466e+38F|Maximum value|
|**`FLT_MAX_10_EXP`**|38|Maximum decimal exponent|
|**`FLT_MAX_EXP`**|128|Maximum binary exponent|
|**`FLT_MIN`**|1.175494351e-38F|Minimum normalized positive value|
|**`FLT_MIN_10_EXP`**|(-37)|Minimum decimal exponent|
|**`FLT_MIN_EXP`**|(-125)|Minimum binary exponent|
|**`FLT_RADIX`**|2|Exponent radix|
|**`FLT_TRUE_MIN`**|1.401298464e-45F|Minimum positive subnormal value|
|**`LDBL_DIG`**|15|# of decimal digits of precision|
|**`LDBL_EPSILON`**|2.2204460492503131e-016|Smallest such that 1.0 + **`LDBL_EPSILON`** != 1.0|
|**`LDBL_HAS_SUBNORM`**|1|Type supports subnormal (denormal) numbers|
|**`LDBL_MANT_DIG`**|53|# of bits in significand (mantissa)|
|**`LDBL_MAX`**|1.7976931348623158e+308|Maximum value|
|**`LDBL_MAX_10_EXP`**|308|Maximum decimal exponent|
|**`LDBL_MAX_EXP`**|1024|Maximum binary exponent|
|**`LDBL_MIN`**|2.2250738585072014e-308|Minimum normalized positive value|
|**`LDBL_MIN_10_EXP`**|(-307)|Minimum decimal exponent|
|**`LDBL_MIN_EXP`**|(-1021)|Minimum binary exponent|
|**`_LDBL_RADIX`**|2|Exponent radix|
|**`LDBL_TRUE_MIN`**|4.9406564584124654e-324|Minimum positive subnormal value|
|**`DECIMAL_DIG`**|same as **`DBL_DECIMAL_DIG`**|Default (double) decimal digits of rounding precision|
|`DBL_DECIMAL_DIG`|17|# of decimal digits of rounding precision|
|`DBL_DIG`|15|# of decimal digits of precision|
|`DBL_EPSILON`|2.2204460492503131e-016|Smallest such that 1.0 + `DBL_EPSILON` != 1.0|
|`DBL_HAS_SUBNORM`|1|Type supports subnormal (denormal) numbers|
|`DBL_MANT_DIG`|53|# of bits in significand (mantissa)|
|`DBL_MAX`|1.7976931348623158e+308|Maximum value|
|`DBL_MAX_10_EXP`|308|Maximum decimal exponent|
|`DBL_MAX_EXP`|1024|Maximum binary exponent|
|`DBL_MIN`|2.2250738585072014e-308|Minimum normalized positive value|
|`DBL_MIN_10_EXP`|(-307)|Minimum decimal exponent|
|`DBL_MIN_EXP`|(-1021)|Minimum binary exponent|
|`_DBL_RADIX`|2|Exponent radix|
|`DBL_TRUE_MIN`|4.9406564584124654e-324|Minimum positive subnormal value|
|`FLT_DECIMAL_DIG`|9|Number of decimal digits of rounding precision|
|`FLT_DIG`|6|Number of decimal digits of precision|
|`FLT_EPSILON`|1.192092896e-07F|Smallest such that 1.0 + `FLT_EPSILON` != 1.0|
|`FLT_HAS_SUBNORM`|1|Type supports subnormal (denormal) numbers|
|`FLT_MANT_DIG`|24|Number of bits in significand (mantissa)|
|`FLT_MAX`|3.402823466e+38F|Maximum value|
|`FLT_MAX_10_EXP`|38|Maximum decimal exponent|
|`FLT_MAX_EXP`|128|Maximum binary exponent|
|`FLT_MIN`|1.175494351e-38F|Minimum normalized positive value|
|`FLT_MIN_10_EXP`|(-37)|Minimum decimal exponent|
|`FLT_MIN_EXP`|(-125)|Minimum binary exponent|
|`FLT_RADIX`|2|Exponent radix|
|`FLT_TRUE_MIN`|1.401298464e-45F|Minimum positive subnormal value|
|`LDBL_DIG`|15|# of decimal digits of precision|
|`LDBL_EPSILON`|2.2204460492503131e-016|Smallest such that 1.0 + `LDBL_EPSILON` != 1.0|
|`LDBL_HAS_SUBNORM`|1|Type supports subnormal (denormal) numbers|
|`LDBL_MANT_DIG`|53|# of bits in significand (mantissa)|
|`LDBL_MAX`|1.7976931348623158e+308|Maximum value|
|`LDBL_MAX_10_EXP`|308|Maximum decimal exponent|
|`LDBL_MAX_EXP`|1024|Maximum binary exponent|
|`LDBL_MIN`|2.2250738585072014e-308|Minimum normalized positive value|
|`LDBL_MIN_10_EXP`|(-307)|Minimum decimal exponent|
|`LDBL_MIN_EXP`|(-1021)|Minimum binary exponent|
|`_LDBL_RADIX`|2|Exponent radix|
|`LDBL_TRUE_MIN`|4.9406564584124654e-324|Minimum positive subnormal value|
|`DECIMAL_DIG`|same as `DBL_DECIMAL_DIG`|Default (double) decimal digits of rounding precision|

## See also

Expand Down
Loading