Skip to content

Commit e3a1f2b

Browse files
author
Colin Robertson
authored
Bulk fix MD004, MD007, MD009, MD019, MD022, MD027 (MicrosoftDocs#2758)
* Bulk fix MD027, MD019 * Fix more MD019 instances * MD022, repair broken headings * Fix stray quotes * revert .markdownlint.json change * More stray quotes
1 parent c0f93cf commit e3a1f2b

File tree

1,585 files changed

+16887
-16886
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,585 files changed

+16887
-16886
lines changed

CONTRIBUTING.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ In this topic, you'll see the basic process for adding or updating content in th
66

77
In this topic, we'll cover:
88

9-
* [Process for contributing](#process-for-contributing)
10-
* [DOs and DON'Ts](#dos-and-donts)
11-
* [Building the docs](#building-the-docs)
12-
* [Contributing to samples](#contributing-to-samples)
13-
* [Contributor license agreement](#contributor-license-agreement)
9+
- [Process for contributing](#process-for-contributing)
10+
- [DOs and DON'Ts](#dos-and-donts)
11+
- [Building the docs](#building-the-docs)
12+
- [Contributing to samples](#contributing-to-samples)
13+
- [Contributor license agreement](#contributor-license-agreement)
1414

1515
## Process for contributing
1616

docs/assembler/inline/inline-assembler.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ ms.assetid: 7e13f18f-3628-4306-8b81-4a6d09c043fe
1111
Assembly language serves many purposes, such as improving program speed, reducing memory needs, and controlling hardware. You can use the inline assembler to embed assembly-language instructions directly in your C and C++ source programs without extra assembly and link steps. The inline assembler is built into the compiler, so you don't need a separate assembler such as the Microsoft Macro Assembler (MASM).
1212

1313
> [!NOTE]
14-
> Programs with inline assembler code are not fully portable to other hardware platforms. If you are designing for portability, avoid using inline assembler.
14+
> Programs with inline assembler code are not fully portable to other hardware platforms. If you are designing for portability, avoid using inline assembler.
1515
1616
Inline assembly is not supported on the ARM and x64 processors. The following topics explain how to use the Visual C/C++ inline assembler with x86 processors:
1717

docs/assembler/inline/using-and-preserving-registers-in-inline-assembly.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ You should preserve other registers you use (such as DS, SS, SP, BP, and flags r
2121
Some SSE types require eight-byte stack alignment, forcing the compiler to emit dynamic stack-alignment code. To be able to access both the local variables and the function parameters after the alignment, the compiler maintains two frame pointers. If the compiler performs frame pointer omission (FPO), it will use EBP and ESP. If the compiler does not perform FPO, it will use EBX and EBP. To ensure code runs correctly, do not modify EBX in asm code if the function requires dynamic stack alignment as it could modify the frame pointer. Either move the eight-byte aligned types out of the function, or avoid using EBX.
2222

2323
> [!NOTE]
24-
> If your inline assembly code changes the direction flag using the STD or CLD instructions, you must restore the flag to its original value.
24+
> If your inline assembly code changes the direction flag using the STD or CLD instructions, you must restore the flag to its original value.
2525
2626
**END Microsoft Specific**
2727

docs/assembler/masm/masm-bnf-grammar.md

+4-5
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ description: "BNF description of MASM for x64."
44
ms.date: "12/17/2019"
55
helpviewer_keywords: ["MASM (Microsoft Macro Assembler), BNF reference"]
66
---
7-
87
# Microsoft Macro Assembler BNF Grammar
98

109
This page contains a BNF description of the MASM grammar. It is provided as a supplement to the reference topics and is not guaranteed to be complete. Please consult the reference topics for full information on keywords, parameters, operations and so on.
@@ -818,7 +817,7 @@ The BNF grammar allows recursive definitions. For example, the grammar uses qual
818817
    *qualifiedType* | **PROTO** *protoSpec*
819818

820819
*quote*\
821-
     |
820+
    " | '
822821

823822
*qwordRegister*\
824823
    RAX | RCX | RDX | RBX | RDI | RSI | RBP | R8 | R9 | R10 | R11 | R12 | R13 | R14 | R15
@@ -924,10 +923,10 @@ untilDir ;;
924923
    **SHR** | **SHL**
925924

926925
*sign*\
927-
- | +
926+
\- | +
928927

929928
*simdRegister*\
930-
    MM0 | MM1 | MM2 | MM3 | MM4 | MM5 | MM6 | MM7 | xmmRegister | YMM0 | YMM1 | YMM2 | YMM3 | YMM4 | YMM5 | YMM6 | YMM7 | YMM8 | YMM9 | YMM10 | YMM11 | YMM12 | YMM13 | YMM14 | YMM15
929+
    MM0 | MM1 | MM2 | MM3 | MM4 | MM5 | MM6 | MM7 | *xmmRegister* | YMM0 | YMM1 | YMM2 | YMM3 | YMM4 | YMM5 | YMM6 | YMM7 | YMM8 | YMM9 | YMM10 | YMM11 | YMM12 | YMM13 | YMM14 | YMM15
931930

932931
*simpleExpr*\
933932
( *cExpr* ) | *primary*
@@ -941,7 +940,7 @@ untilDir ;;
941940
*specialChars*\
942941
: | . | ⟦ | ⟧ | ( | ) | < | > | { | }\
943942
&nbsp;&nbsp;&nbsp;&nbsp;| + | - | / | * | & | % | !\
944-
&nbsp;&nbsp;&nbsp;&nbsp;| | \ | = | ; | , | \
943+
&nbsp;&nbsp;&nbsp;&nbsp;| ' | \ | = | ; | , | "\
945944
&nbsp;&nbsp;&nbsp;&nbsp;| *whiteSpaceCharacter*\
946945
&nbsp;&nbsp;&nbsp;&nbsp;| *endOfLine*
947946

docs/atl-mfc-shared/basic-cstring-operations.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ This topic explains the following basic [CString](../atl-mfc-shared/reference/cs
2626

2727
Note: `CString` is a native class. For a string class that is for use in a C++/CLI managed project, use `System.String`.
2828

29-
## <a name="_core_creating_cstring_objects_from_standard_c_literal_strings"></a> Creating CString Objects from Standard C Literal Strings
29+
## <a name="_core_creating_cstring_objects_from_standard_c_literal_strings"></a> Creating CString Objects from Standard C Literal Strings
3030

3131
You can assign C-style literal strings to a `CString` just as you can assign one `CString` object to another.
3232

@@ -43,19 +43,19 @@ You can assign C-style literal strings to a `CString` just as you can assign one
4343
> [!NOTE]
4444
> To write your application so that it can be compiled for Unicode or for ANSI, code literal strings by using the _T macro. For more information, see [Unicode and Multibyte Character Set (MBCS) Support](../atl-mfc-shared/unicode-and-multibyte-character-set-mbcs-support.md).
4545
46-
## <a name="_core_accessing_individual_characters_in_a_cstring"></a> Accessing Individual Characters in a CString
46+
## <a name="_core_accessing_individual_characters_in_a_cstring"></a> Accessing Individual Characters in a CString
4747

4848
You can access individual characters in a `CString` object by using the `GetAt` and `SetAt` methods. You can also use the array element, or subscript, operator ( [ ] ) instead of `GetAt` to get individual characters. (This resembles accessing array elements by index, as in standard C-style strings.) Index values for `CString` characters are zero-based.
4949

50-
## <a name="_core_concatenating_two_cstring_objects"></a> Concatenating Two CString Objects
50+
## <a name="_core_concatenating_two_cstring_objects"></a> Concatenating Two CString Objects
5151

5252
To concatenate two `CString` objects, use the concatenation operators (+ or +=), as follows.
5353

5454
[!code-cpp[NVC_ATLMFC_Utilities#185](../atl-mfc-shared/codesnippet/cpp/basic-cstring-operations_3.cpp)]
5555

5656
At least one argument to the concatenation operators (+ or +=) must be a `CString` object, but you can use a constant character string (for example, `"big"`) or a **char** (for example, 'x') for the other argument.
5757

58-
## <a name="_core_comparing_cstring_objects"></a> Comparing CString Objects
58+
## <a name="_core_comparing_cstring_objects"></a> Comparing CString Objects
5959

6060
The `Compare` method and the == operator for `CString` are equivalent. `Compare`, **operator==**, and `CompareNoCase` are MBCS and Unicode aware; `CompareNoCase` is also case-insensitive. The `Collate` method of `CString` is locale-sensitive and is often slower than `Compare`. Use `Collate` only where you must abide by the sorting rules as specified by the current locale.
6161

@@ -71,7 +71,7 @@ The `CStringT` class template defines the relational operators (<, \<=, >=, >, =
7171

7272
[!code-cpp[NVC_ATLMFC_Utilities#186](../atl-mfc-shared/codesnippet/cpp/basic-cstring-operations_4.cpp)]
7373

74-
## <a name="_core_converting_cstring_objects"></a> Converting CString Objects
74+
## <a name="_core_converting_cstring_objects"></a> Converting CString Objects
7575

7676
For information about converting CString objects to other string types, see [How to: Convert Between Various String Types](../text/how-to-convert-between-various-string-types.md).
7777

docs/atl-mfc-shared/cstring-argument-passing.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,19 @@ ms.assetid: a67bebff-edf1-4cf4-bbff-d1cc6a901099
88

99
This article explains how to pass [CString](../atl-mfc-shared/reference/cstringt-class.md) objects to functions and how to return `CString` objects from functions.
1010

11-
## <a name="_core_cstring_argument.2d.passing_conventions"></a> CString Argument-Passing Conventions
11+
## <a name="_core_cstring_argument.2d.passing_conventions"></a> CString Argument-Passing Conventions
1212

1313
When you define a class interface, you must determine the argument-passing convention for your member functions. There are some standard rules for passing and returning `CString` objects. If you follow the rules described in [Strings as Function Inputs](#_core_strings_as_function_inputs) and [Strings as Function Outputs](#_core_strings_as_function_outputs), you will have efficient, correct code.
1414

15-
## <a name="_core_strings_as_function_inputs"></a> Strings as Function Inputs
15+
## <a name="_core_strings_as_function_inputs"></a> Strings as Function Inputs
1616

1717
The most efficient and secure way to use a `CString` object in called functions is to pass a `CString` object to the function. Despite the name, a `CString` object does not store a string internally as a C-style string that has a null terminator. Instead, a `CString` object keeps careful track of the number of characters it has. Having `CString` provide a LPCTSTR pointer to a null-terminated string is a small amount of work that can become significant if your code has to do it constantly. The result is temporary because any change to the `CString` contents invalidates old copies of the LPCTSTR pointer.
1818

1919
It does make sense in some cases to provide a C-style string. For example, there can be a situation where a called function is written in C and does not support objects. In this case, coerce the `CString` parameter to LPCTSTR, and the function will get a C-style null-terminated string. You can also go the other direction and create a `CString` object by using the `CString` constructor that accepts a C-style string parameter.
2020

2121
If the string contents are to be changed by a function, declare the parameter as a nonconstant `CString` reference (`CString&`).
2222

23-
## <a name="_core_strings_as_function_outputs"></a> Strings as Function Outputs
23+
## <a name="_core_strings_as_function_outputs"></a> Strings as Function Outputs
2424

2525
Typically you can return `CString` objects from functions because `CString` objects follow value semantics like primitive types. To return a read-only string, use a constant `CString` reference (`const CString&`). The following example illustrates the use of `CString` parameters and return types:
2626

docs/atl-mfc-shared/cstring-operations-relating-to-c-style-strings.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ A [CString](../atl-mfc-shared/using-cstring.md) object contains character string
2222

2323
- [Specifying CString formal parameters](#_core_specifying_cstring_formal_parameters)
2424

25-
## <a name="_core_using_cstring_as_a_c.2d.style_null.2d.terminated_string"></a> Using CString as a C-Style Null-Terminated String
25+
## <a name="_core_using_cstring_as_a_c.2d.style_null.2d.terminated_string"></a> Using CString as a C-Style Null-Terminated String
2626

2727
To use a `CString` object as a C-style string, cast the object to LPCTSTR. In the following example, the `CString` returns a pointer to a read-only C-style null-terminated string. The `strcpy` function puts a copy of the C-style string in the variable `myString`.
2828

@@ -41,13 +41,13 @@ Sometimes you may require a copy of `CString` data to modify directly. Use the m
4141
> [!NOTE]
4242
> The third argument to `strcpy_s` (or the Unicode/MBCS-portable `_tcscpy_s`) is either a `const wchar_t*` (Unicode) or a `const char*` (ANSI). The example above passes a `CString` for this argument. The C++ compiler automatically applies the conversion function defined for the `CString` class that converts a `CString` to an `LPCTSTR`. The ability to define casting operations from one type to another is one of the most useful features of C++.
4343
44-
## <a name="_core_working_with_standard_run.2d.time_library_string_functions"></a> Working with Standard Run-Time Library String Functions
44+
## <a name="_core_working_with_standard_run.2d.time_library_string_functions"></a> Working with Standard Run-Time Library String Functions
4545
4646
You should be able to find a `CString` method to perform any string operation for which you might consider using the standard C run-time library string functions such as `strcmp` (or the Unicode/MBCS-portable `_tcscmp`).
4747
4848
If you must use the C run-time string functions, you can use the techniques described in _core_using_cstring_as_a_c.2d.style_null.2d.terminated_string. You can copy the `CString` object to an equivalent C-style string buffer, perform your operations on the buffer, and then assign the resulting C-style string back to a `CString` object.
4949
50-
## <a name="_core_modifying_cstring_contents_directly"></a> Modifying CString Contents Directly
50+
## <a name="_core_modifying_cstring_contents_directly"></a> Modifying CString Contents Directly
5151
5252
In most situations, you should use `CString` member functions to modify the contents of a `CString` object or to convert the `CString` to a C-style character string.
5353
@@ -63,15 +63,15 @@ The `GetBuffer` and `ReleaseBuffer` methods offer access to the internal charact
6363
6464
1. Call `ReleaseBuffer` for the `CString` object to update all the internal `CString` state information, for example, the length of the string. After you modify the contents of a `CString` object directly, you must call `ReleaseBuffer` before you call any other `CString` member functions.
6565
66-
## <a name="_core_using_cstring_objects_with_variable_argument_functions"></a> Using CString Objects with Variable Argument Functions
66+
## <a name="_core_using_cstring_objects_with_variable_argument_functions"></a> Using CString Objects with Variable Argument Functions
6767
6868
Some C functions take a variable number of arguments. A notable example is `printf_s`. Because of the way this kind of function is declared, the compiler cannot be sure of the type of the arguments and cannot determine which conversion operation to perform on each argument. Therefore, it is essential that you use an explicit type cast when passing a `CString` object to a function that takes a variable number of arguments.
6969
7070
To use a `CString` object in a variable argument function, explicitly cast the `CString` to an LPCTSTR string, as shown in the following example.
7171
7272
[!code-cpp[NVC_ATLMFC_Utilities#190](../atl-mfc-shared/codesnippet/cpp/cstring-operations-relating-to-c-style-strings_2.cpp)]
7373
74-
## <a name="_core_specifying_cstring_formal_parameters"></a> Specifying CString Formal Parameters
74+
## <a name="_core_specifying_cstring_formal_parameters"></a> Specifying CString Formal Parameters
7575
7676
For most functions that need a string argument, it is best to specify the formal parameter in the function prototype as a `const` pointer to a character (`LPCTSTR`) instead of a `CString`. When a formal parameter is specified as a `const` pointer to a character, you can pass either a pointer to a TCHAR array, a literal string [`"hi there"`], or a `CString` object. The `CString` object will be automatically converted to an LPCTSTR. Any place you can use an LPCTSTR, you can also use a `CString` object.
7777

docs/atl-mfc-shared/date-type.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ The following points should be noted when working with these date and time forma
4747
|2 January 1900, midnight|3.00|
4848

4949
> [!CAUTION]
50-
> Note that because 6:00 AM is always represented by a fractional value 0.25 regardless of whether the integer representing the day is positive (after December 30, 1899) or negative (before December 30, 1899), a simple floating point comparison would erroneously sort any DATE representing 6:00 AM on a day earlier than 12/30/1899 as *later* than a DATE representing 7:00 AM on that same day.
50+
> Note that because 6:00 AM is always represented by a fractional value 0.25 regardless of whether the integer representing the day is positive (after December 30, 1899) or negative (before December 30, 1899), a simple floating point comparison would erroneously sort any DATE representing 6:00 AM on a day earlier than 12/30/1899 as *later* than a DATE representing 7:00 AM on that same day.
5151
5252
More information on issues related to the DATE and `COleDateTime` types can be found under [COleDateTime Class](../atl-mfc-shared/reference/coledatetime-class.md) and [Date and Time: Automation Support](../atl-mfc-shared/date-and-time-automation-support.md).
5353

0 commit comments

Comments
 (0)