Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
0d52b22
Fix invalid `std::` prefix for `public` keyword in `value_compare` cl…
Rageking8 Jul 18, 2025
0c929e0
Add backticks in `value_compare` class reference
Rageking8 Jul 18, 2025
02037fb
Simplify redundant relative links in `value_compare` class reference
Rageking8 Jul 18, 2025
2a713d6
Update metadata in `value_compare` class reference
Rageking8 Jul 18, 2025
91e5c22
Add backticks in "EVEN and ALIGN Directives" topic
Rageking8 Jul 19, 2025
d15a34b
Simplify and add links in "EVEN and ALIGN Directives" topic
Rageking8 Jul 19, 2025
8377f62
Remove unneeded `br` element in "EVEN and ALIGN Directives" topic
Rageking8 Jul 19, 2025
6ac88d6
Update metadata in "EVEN and ALIGN Directives" topic
Rageking8 Jul 19, 2025
a62287a
Add backticks for heading in `EVEN` MASM reference
Rageking8 Jul 19, 2025
1422692
Add `ALIGN` to "See also" in `EVEN` MASM reference
Rageking8 Jul 19, 2025
b07d182
Update metadata in `EVEN` MASM reference
Rageking8 Jul 19, 2025
cbd976c
Add blockquotes for error messages in range [C2201, C2230]
Rageking8 Jul 19, 2025
5514520
Add "Remarks" and "Example" headings for error references in range [C…
Rageking8 Jul 19, 2025
f1c6d3d
Replace term "sample" with "example" for error references in range [C…
Rageking8 Jul 19, 2025
d8b7672
Update metadata for error references in range [C2201, C2230]
Rageking8 Jul 19, 2025
6d2ec4e
Fix title in C4335 warning reference
Rageking8 Jul 20, 2025
1244cc2
Add "Remarks" heading in C4335 warning reference
Rageking8 Jul 20, 2025
9b70f50
Tweak "Example" text in C4335 warning reference
Rageking8 Jul 20, 2025
31cd15c
Update metadata in C4335 warning reference
Rageking8 Jul 20, 2025
ed7f32d
Update warning level flag for example in C4373 warning reference
Rageking8 Jul 20, 2025
4815abc
Update metadata in C4373 warning reference
Rageking8 Jul 20, 2025
245c698
Add blockquotes for error messages in range [C2231, C2260]
Rageking8 Jul 20, 2025
6756cd9
Add "Remarks" and "Example" headings for error references in range [C…
Rageking8 Jul 20, 2025
901cb65
Replace term "sample" with "example" for error references in range [C…
Rageking8 Jul 20, 2025
c17ce23
Update metadata for error references in range [C2231, C2260]
Rageking8 Jul 20, 2025
638bafc
Merge pull request #5565 from Rageking8/structure-error-references-in…
v-dirichards Aug 22, 2025
07e2547
Merge pull request #5563 from Rageking8/update-warning-level-flag-for…
v-dirichards Aug 22, 2025
a79eced
Merge pull request #5562 from Rageking8/fix-title-and-update-c4335-wa…
v-dirichards Aug 22, 2025
bd55c05
Merge pull request #5561 from Rageking8/structure-error-references-in…
v-dirichards Aug 22, 2025
5110b0c
Merge pull request #5559 from Rageking8/tweak-even-masm-reference
v-dirichards Aug 22, 2025
fc1ac7b
Merge pull request #5558 from Rageking8/update-even-and-align-directi…
v-dirichards Aug 22, 2025
1a7e1a4
Merge pull request #5553 from Rageking8/fix-invalid-std-prefix-for-pu…
v-dirichards Aug 22, 2025
5874ccd
Merge pull request #6053 from MicrosoftDocs/FromPublicMasterBranch
Albertyang0 Aug 22, 2025
73dc2d2
Merge pull request #6054 from MicrosoftDocs/main
learn-build-service-prod[bot] Aug 22, 2025
565ac29
Merge pull request #5697 from MicrosoftDocs/main638914808699352304syn…
learn-build-service-prod[bot] Aug 22, 2025
20ed867
Structure error references in range [C2291, C2320] (#5570)
Rageking8 Aug 22, 2025
b3fb9c6
Add `cmd` language for CL and LINK invocations (#5568)
Rageking8 Aug 22, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions docs/assembler/inline/even-and-align-directives.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,17 @@
---
description: "Learn more about: EVEN and ALIGN Directives"
title: "EVEN and ALIGN Directives"
ms.date: "08/30/2018"
description: "Learn more about: EVEN and ALIGN Directives"
ms.date: 08/30/2018
helpviewer_keywords: ["EVEN directive", "directives, MASM", "MASM (Microsoft Macro Assembler), directives", "NOP (no operation instruction)", "ALIGN directive"]
ms.assetid: 7357ab2d-4a5c-43ca-accb-a5f21cdfcde5
---
# EVEN and ALIGN Directives
# `EVEN` and `ALIGN` Directives

**Microsoft Specific**

Although the inline assembler doesn't support most MASM directives, it does support `EVEN` and **ALIGN**. These directives put **NOP** (no operation) instructions in the assembly code as needed to align labels to specific boundaries. This makes instruction-fetch operations more efficient for some processors.
Although the inline assembler doesn't support most MASM directives, it does support [`EVEN`](../masm/even.md) and [`ALIGN`](../masm/align-masm.md). These directives put `NOP` (no operation) instructions in the assembly code as needed to align labels to specific boundaries. This makes instruction-fetch operations more efficient for some processors.

**END Microsoft Specific**

## See also

[Using Assembly Language in __asm Blocks](../../assembler/inline/using-assembly-language-in-asm-blocks.md)<br/>
[Using Assembly Language in `__asm` Blocks](using-assembly-language-in-asm-blocks.md)
8 changes: 4 additions & 4 deletions docs/assembler/masm/even.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
---
description: "Learn more about: EVEN"
title: "EVEN"
ms.date: "12/17/2019"
description: "Learn more about: EVEN"
ms.date: 12/17/2019
f1_keywords: ["EVEN"]
helpviewer_keywords: ["EVEN directive"]
ms.assetid: 68938ba4-8cb9-44d4-914e-9f9fee6bcbf4
---
# EVEN
# `EVEN`

Aligns the next variable or instruction on an even byte.

Expand All @@ -16,5 +15,6 @@ Aligns the next variable or instruction on an even byte.

## See also

[`ALIGN`](align-masm.md)\
[Directives reference](directives-reference.md)\
[MASM BNF Grammar](masm-bnf-grammar.md)
9 changes: 4 additions & 5 deletions docs/build/reference/c-compile-without-linking.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
---
description: "Learn more about: /c (Compile Without Linking)"
title: "/c (Compile Without Linking)"
ms.date: "11/04/2016"
description: "Learn more about: /c (Compile Without Linking)"
ms.date: 11/04/2016
f1_keywords: ["/c"]
helpviewer_keywords: ["suppress link", "cl.exe compiler, compiling without linking", "-c compiler option [C++]", "c compiler option [C++]", "/c compiler option [C++]"]
ms.assetid: 8017fc3d-e5dd-4668-a1f7-3120daa95d20
---
# /c (Compile Without Linking)

Expand Down Expand Up @@ -34,13 +33,13 @@ Any internal project created in the development environment uses the **/c** opti

The following command line creates the object files FIRST.obj and SECOND.obj. THIRD.obj is ignored.

```
```cmd
CL /c FIRST.C SECOND.C THIRD.OBJ
```

To create an executable file, you must invoke LINK:

```
```cmd
LINK first.obj second.obj third.obj /OUT:filename.exe
```

Expand Down
7 changes: 3 additions & 4 deletions docs/build/reference/cl-invokes-the-linker.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
description: "Learn more about: CL Invokes the Linker"
title: "CL Invokes the Linker"
ms.date: "11/04/2016"
description: "Learn more about: CL Invokes the Linker"
ms.date: 11/04/2016
helpviewer_keywords: ["compiling source code [C++], without linking", "invoking linker from the compiler", "LINK tool [C++], invoking from CL compiler", "cl.exe compiler [C++], compiling without linking", "cl.exe compiler [C++], controlling linker"]
ms.assetid: eae47ef7-09eb-40c9-b318-7c714cd452fc
---
# CL Invokes the Linker

Expand All @@ -30,7 +29,7 @@ Assume that you are compiling three C source files: MAIN.c, MOD1.c, and MOD2.c.

To build this program, compile with the following command line:

```
```cmd
CL MAIN.c MOD1.C MOD2.C MYGRAPH.lib
```

Expand Down
7 changes: 3 additions & 4 deletions docs/build/reference/compiler-command-line-syntax.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
---
description: "Learn more about: Compiler Command-Line Syntax"
title: "MSVC Compiler Command-Line Syntax"
ms.date: "11/04/2016"
description: "Learn more about: Compiler Command-Line Syntax"
ms.date: 11/04/2016
helpviewer_keywords: ["syntax, CL compiler command line", "cl.exe compiler, command-line syntax"]
ms.assetid: acba2c1c-0803-4a3a-af25-63e849b930a2
---
# Compiler Command-Line Syntax

The CL command line uses the following syntax:

```
```cmd
CL [option...] file... [option | file]... [lib...] [@command-file] [/link link-opt...]
```

Expand Down
9 changes: 4 additions & 5 deletions docs/build/reference/e-preprocess-to-stdout.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
---
description: "Learn more about: /E (Preprocess to stdout)"
title: "/E (Preprocess to stdout)"
ms.date: "11/04/2016"
description: "Learn more about: /E (Preprocess to stdout)"
ms.date: 11/04/2016
f1_keywords: ["/e"]
helpviewer_keywords: ["-E compiler option [C++]", "/E compiler option [C++]", "preprocessor output, copy to stdout", "preprocessor output"]
ms.assetid: ddbb1725-d950-4978-ab2f-30a5cd7b778c
---
# /E (Preprocess to stdout)

Expand Down Expand Up @@ -44,7 +43,7 @@ m(int)main( )

However, if you compile with:

```
```cmd
cl -E test.cpp > test2.cpp
```

Expand All @@ -66,7 +65,7 @@ cl -E test.cpp > test2.cpp

The following command line preprocesses `ADD.C`, preserves comments, adds `#line` directives, and displays the result on the standard output device:

```
```cmd
CL /E /C ADD.C
```

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
---
description: "Learn more about: /EP (Preprocess to stdout Without #line Directives)"
title: "/EP (Preprocess to stdout Without #line Directives)"
ms.date: "11/04/2016"
description: "Learn more about: /EP (Preprocess to stdout Without #line Directives)"
ms.date: 11/04/2016
f1_keywords: ["/ep", "VC.Project.VCCLCompilerTool.GeneratePreprocessedFileNoLines"]
helpviewer_keywords: ["copy preprocessor output to stdout", "preprocessor output, copy to stdout", "-EP compiler option [C++]", "EP compiler option [C++]", "/EP compiler option [C++]"]
ms.assetid: 6ec411ae-e33d-4ef5-956e-0054635eabea
---
# /EP (Preprocess to stdout Without #line Directives)

Expand Down Expand Up @@ -46,7 +45,7 @@ You cannot use precompiled headers with the **/EP** option.

The following command line preprocesses file `ADD.C`, preserves comments, and displays the result on the standard output device:

```
```cmd
CL /EP /C ADD.C
```

Expand Down
7 changes: 3 additions & 4 deletions docs/build/reference/fd-program-database-file-name.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
---
description: "Learn more about: /Fd (Program Database File Name)"
title: "/Fd (Program Database File Name)"
ms.date: "11/04/2016"
description: "Learn more about: /Fd (Program Database File Name)"
ms.date: 11/04/2016
f1_keywords: ["/FD", "VC.Project.VCCLWCECompilerTool.ProgramDataBaseFileName", "VC.Project.VCCLCompilerTool.ProgramDataBaseFileName"]
helpviewer_keywords: ["/FD compiler option [C++]", "program database file name [C++]", "-FD compiler option [C++]", "PDB files, creating", "program database compiler option [C++]", ".pdb files, creating", "FD compiler option [C++]"]
ms.assetid: 3977a9ed-f0ac-45df-bf06-01cedd2ba85a
---
# /Fd (Program Database File Name)

Expand Down Expand Up @@ -42,7 +41,7 @@ This option also names the state (.idb) file used for minimal rebuild and increm

This command line creates a .pdb file named PROG.pdb and an .idb file named PROG.idb:

```
```cmd
CL /DDEBUG /Zi /FdPROG.PDB PROG.CPP
```

Expand Down
9 changes: 4 additions & 5 deletions docs/build/reference/fe-name-exe-file.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
---
description: "Learn more about: /Fe (Name EXE File)"
title: "/Fe (Name EXE File)"
ms.date: "11/04/2016"
description: "Learn more about: /Fe (Name EXE File)"
ms.date: 11/04/2016
f1_keywords: ["/fe"]
helpviewer_keywords: ["-Fe compiler option [C++]", "executable files, renaming", "rename file compiler option [C++]", "/Fe compiler option [C++]", "Fe compiler option [C++]"]
ms.assetid: 49f594fd-5e94-45fe-a1bf-7c9f2abb6437
---
# /Fe (Name EXE File)

Expand Down Expand Up @@ -44,13 +43,13 @@ If you specify the [/c (Compile Without Linking)](c-compile-without-linking.md)

The following command line compiles and links all C source files in the current directory. The resulting executable file is named PROCESS.exe and is created in the directory "C:\Users\User Name\repos\My Project\bin".

```
```cmd
CL /Fe"C:\Users\User Name\repos\My Project\bin\PROCESS" *.C
```

The following command line creates an executable file in `C:\BIN` with the same base name as the first source file in the current directory:

```
```cmd
CL /FeC:\BIN\ *.C
```

Expand Down
7 changes: 3 additions & 4 deletions docs/build/reference/p-preprocess-to-a-file.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
---
description: "Learn more about: /P (Preprocess to a File)"
title: "/P (Preprocess to a File)"
ms.date: "11/04/2016"
description: "Learn more about: /P (Preprocess to a File)"
ms.date: 11/04/2016
f1_keywords: ["VC.Project.VCCLCompilerTool.GeneratePreprocessedFile", "/p", "VC.Project.VCCLWCECompilerTool.GeneratePreprocessedFile"]
helpviewer_keywords: ["/P compiler option [C++]", "-P compiler option [C++]", "P compiler option [C++]", "output files, preprocessor", "preprocessing output files"]
ms.assetid: 123ee54f-8219-4a6f-9876-4227023d83fc
---
# /P (Preprocess to a File)

Expand Down Expand Up @@ -40,7 +39,7 @@ The **/P** option suppresses compilation. It does not produce an .obj file, even

The following command line preprocesses `ADD.C`, preserves comments, adds `#line` directives, and writes the result to a file, `ADD.I`:

```
```cmd
CL /P /C ADD.C
```

Expand Down
7 changes: 3 additions & 4 deletions docs/build/reference/specifying-the-pathname.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
---
description: "Learn more about: Specifying the Pathname"
title: "Specifying the Pathname"
ms.date: "11/04/2016"
description: "Learn more about: Specifying the Pathname"
ms.date: 11/04/2016
helpviewer_keywords: ["names [C++], compiler output files", "cl.exe compiler, output files", "output files, specifying pathnames"]
ms.assetid: 7a6595ce-3383-44ae-957a-466bfa29c343
---
# Specifying the Pathname

Expand All @@ -24,7 +23,7 @@ Alternatively, the *pathname* argument can be a device name (AUX, CON, PRN, or N

The following command line sends a mapfile to the printer:

```
```cmd
CL /FmPRN HELLO.CPP
```

Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
---
description: "Learn more about: /Yd (Place Debug Information in Object File)"
title: "/Yd (Place Debug Information in Object File)"
ms.date: "11/04/2016"
description: "Learn more about: /Yd (Place Debug Information in Object File)"
ms.date: 11/04/2016
f1_keywords: ["/yd"]
helpviewer_keywords: ["/Yd compiler option [C++]", "-Yd compiler option [C++]", "debugging [C++], debug information files", "Yd compiler option [C++]"]
ms.assetid: c5a699fe-65ce-461e-964c-7f5eb2a8320a
---
# /Yd (Place Debug Information in Object File)

Expand Down Expand Up @@ -55,13 +54,13 @@ Suppose you have two base files, F.cpp and G.cpp, each containing these **#inclu

The following command creates the precompiled header file ETC.pch and the object file F.obj:

```
```cmd
CL /YcETC.H /Z7 F.CPP
```

The object file F.obj includes type and symbol information for WINDOWS.h and ETC.h (and any other header files they include). Now you can use the precompiled header ETC.pch to compile the source file G.cpp:

```
```cmd
CL /YuETC.H /Z7 G.CPP
```

Expand Down
6 changes: 4 additions & 2 deletions docs/error-messages/compiler-errors-1/compiler-error-c2201.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
description: "Learn more about: Compiler Error C2201"
title: "Compiler Error C2201"
description: "Learn more about: Compiler Error C2201"
ms.date: 05/03/2021
f1_keywords: ["C2201"]
helpviewer_keywords: ["C2201"]
Expand All @@ -9,11 +9,13 @@ helpviewer_keywords: ["C2201"]

> '*identifier*' : must have external linkage in order to be exported/imported

## Remarks

The exported identifier is **`static`**.

## Example

The following sample generates C2286, and shows how to fix it:
The following example generates C2286, and shows how to fix it:

```cpp
// C2201.cpp
Expand Down
13 changes: 8 additions & 5 deletions docs/error-messages/compiler-errors-1/compiler-error-c2203.md
Original file line number Diff line number Diff line change
@@ -1,18 +1,21 @@
---
description: "Learn more about: Compiler Error C2203"
title: "Compiler Error C2203"
ms.date: "11/04/2016"
description: "Learn more about: Compiler Error C2203"
ms.date: 11/04/2016
f1_keywords: ["C2203"]
helpviewer_keywords: ["C2203"]
ms.assetid: 5497df43-86f6-43d5-b6cb-723c4c589b10
---
# Compiler Error C2203

delete operator cannot specify bounds for an array
> delete operator cannot specify bounds for an array

## Remarks

With the **/Za** (ANSI) option, the **`delete`** operator can delete an entire array but not parts or specific members of the array.

The following sample generates C2203:
## Example

The following example generates C2203:

```cpp
// C2203.cpp
Expand Down
9 changes: 5 additions & 4 deletions docs/error-messages/compiler-errors-1/compiler-error-c2204.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
---
description: "Learn more about: Compiler Error C2204"
title: "Compiler Error C2204"
ms.date: "11/04/2016"
description: "Learn more about: Compiler Error C2204"
ms.date: 11/04/2016
f1_keywords: ["C2204"]
helpviewer_keywords: ["C2204"]
ms.assetid: bbe506d4-7863-44af-8709-161881c4b4ba
---
# Compiler Error C2204

'type' : type definition found within parentheses
> 'type' : type definition found within parentheses

## Remarks

The type is defined as an operand or in prototype scope.
9 changes: 5 additions & 4 deletions docs/error-messages/compiler-errors-1/compiler-error-c2205.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
---
description: "Learn more about: Compiler Error C2205"
title: "Compiler Error C2205"
ms.date: "11/04/2016"
description: "Learn more about: Compiler Error C2205"
ms.date: 11/04/2016
f1_keywords: ["C2205"]
helpviewer_keywords: ["C2205"]
ms.assetid: bfc19840-4a48-4da5-8e69-7069989f1d2c
---
# Compiler Error C2205

'identifier' : cannot initialize extern variables with block scope
> 'identifier' : cannot initialize extern variables with block scope

## Remarks

An **`extern`** variable cannot be initialized in a function.
Loading