Skip to content

Commit 3e4b0a8

Browse files
author
Colin Robertson
authored
Merge pull request #1740 from NextTurn/cpp-14
Add language identifiers
2 parents 9fddbf3 + 0bbdfdc commit 3e4b0a8

20 files changed

+22
-22
lines changed

docs/error-messages/compiler-warnings/compiler-warning-level-3-c4823.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ You can also manually unpin the object and ignore the warning.
1717

1818
The following sample generates C4823.
1919

20-
```
20+
```cpp
2121
// C4823.cpp
2222
// compile with: /clr /W3 /EHa-
2323
using namespace System;

docs/error-messages/compiler-warnings/compiler-warning-level-3-c4995.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ The compiler encountered a function that was marked with pragma [deprecated](../
1515

1616
The following sample generates C4995:
1717

18-
```
18+
```cpp
1919
// C4995.cpp
2020
// compile with: /W3
2121
#include <stdio.h>

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4001.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Under strict ANSI compatibility ([/Za](../../build/reference/za-ze-disable-langu
1919

2020
To disable warning, uncomment [#pragma warning(disable:4001)](../../preprocessor/warning.md).
2121

22-
```
22+
```cpp
2323
// C4001.cpp
2424
// compile with: /W4 /Za /TC
2525
// #pragma warning(disable:4001)

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4019.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ This warning may be fixed if you remove the extra semicolon.
1515

1616
## Example
1717

18-
```
18+
```c
1919
// C4019.c
2020
// compile with: /Za /W4
2121
#define declint( varname ) int varname;

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4032.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ This is an error in ANSI C ([/Za](../../build/reference/za-ze-disable-language-e
1515

1616
## Example
1717

18-
```
18+
```c
1919
// C4032.c
2020
// compile with: /W4
2121
void func();

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4100.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ C4100 can also be issued when code calls a destructor on a otherwise unreference
1515

1616
The following sample generates C4100:
1717

18-
```
18+
```cpp
1919
// C4100.cpp
2020
// compile with: /W4
2121
void func(int i) { // C4100, delete the unreferenced parameter to

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4121.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ ms.assetid: 8c5b85c9-2543-426b-88bc-319c50158c7e
1111

1212
The compiler added padding to align a structure member on the packing boundary but the packing value is less than the member's size. For example, the following code snippet produces C4121:
1313

14-
```
14+
```cpp
1515
// C4121.cpp
1616
// compile with: /W4 /c
1717
#pragma pack(2)

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4125.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ The compiler evaluates the octal number without the decimal digit and assumes th
1313

1414
## Example
1515

16-
```
16+
```cpp
1717
// C4125a.cpp
1818
// compile with: /W4
1919
char array1[] = "\709"; // C4125
@@ -24,7 +24,7 @@ int main()
2424

2525
If the digit 9 is intended as a character, correct the example as follows:
2626

27-
```
27+
```cpp
2828
// C4125b.cpp
2929
// compile with: /W4
3030
char array[] = "\0709"; // C4125 String containing "89"

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4130.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Using the operator with the address of a string literal produces unexpected code
1313

1414
The following sample generates C4130:
1515

16-
```
16+
```cpp
1717
// C4130.cpp
1818
// compile with: /W4
1919
int main()

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4131.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Old-style function declarations should be converted to prototype form.
1515

1616
The following example shows an old-style function declaration:
1717

18-
```
18+
```c
1919
// C4131.c
2020
// compile with: /W4 /c
2121
void addrec( name, id ) // C4131 expected
@@ -26,7 +26,7 @@ int id;
2626
2727
The following example shows a prototype form:
2828
29-
```
29+
```c
3030
void addrec( char *name, int id )
3131
{ }
3232
```

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4189.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ A variable is declared and initialized but not used.
1313

1414
The following sample generates C4189:
1515

16-
```
16+
```cpp
1717
// C4189.cpp
1818
// compile with: /W4
1919
int main() {

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4201.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Under Microsoft extensions (/Ze), you can specify a structure without a declarat
1313

1414
## Example
1515

16-
```
16+
```cpp
1717
// C4201.cpp
1818
// compile with: /W4
1919
struct S

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4202.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ An old-style function definition contains variable arguments. These definitions
1313

1414
## Example
1515

16-
```
16+
```c
1717
// C4202.c
1818
// compile with: /W4
1919
void func( a, b, ...) // C4202

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4204.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ With Microsoft extensions (/Ze), you can initialize aggregate types (arrays, str
1313

1414
## Example
1515

16-
```
16+
```c
1717
// C4204.c
1818
// compile with: /W4
1919
int func1()

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4205.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ With Microsoft extensions (/Ze), **static** functions can be declared inside ano
1313

1414
## Example
1515

16-
```
16+
```c
1717
// C4205.c
1818
// compile with: /W4
1919
void func1()

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4207.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ With Microsoft extensions (/Ze), you can initialize an unsized array of `char` u
1313

1414
## Example
1515

16-
```
16+
```c
1717
// C4207.c
1818
// compile with: /W4
1919
char c[] = { 'a', 'b', "cdefg" }; // C4207

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4208.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ nonstandard extension used : delete [exp] - exp evaluated but ignored
1111

1212
With Microsoft extensions (/Ze), you can delete an array using a value within brackets with the [delete operator](../../cpp/delete-operator-cpp.md). The value is ignored.
1313

14-
```
14+
```cpp
1515
// C4208.cpp
1616
// compile with: /W4
1717
int main()

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4210.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ nonstandard extension used : function given file scope
1111

1212
With the default Microsoft extensions ([/Ze](../../build/reference/za-ze-disable-language-extensions.md)), function declarations have file scope.
1313

14-
```
14+
```c
1515
// C4210.c
1616
// compile with: /W4 /c
1717
void func1()

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4211.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ With the default Microsoft extensions (/Ze), you can redefine an `extern` identi
1313

1414
## Example
1515

16-
```
16+
```c
1717
// C4211.c
1818
// compile with: /W4
1919
extern int i;

docs/error-messages/compiler-warnings/compiler-warning-level-4-c4212.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ The function prototype has a variable number of arguments. The function definiti
1313

1414
The following sample generates C4212:
1515

16-
```
16+
```c
1717
// C4212.c
1818
// compile with: /W4 /Ze /c
1919
void f(int , ...);

0 commit comments

Comments
 (0)