Skip to content

Commit a527184

Browse files
author
Colin Robertson
authored
Merge branch 'master' into docs/corob/chrono-3
2 parents 2d8f0b1 + ba4d716 commit a527184

Some content is hidden

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

44 files changed

+2534
-252
lines changed

docs/build/reference/experimental-module.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ ms.date: "04/13/2021"
55
f1_keywords: ["module", "/experimental:module"]
66
helpviewer_keywords: ["module", "/experimental:module", "Enable module support"]
77
---
8-
# /experimental:module (Enable module support)
8+
# `/experimental:module` (Enable module support)
99

1010
Enables experimental compiler support for Standard Template Library named modules.
1111

Lines changed: 27 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,53 @@
11
---
2-
description: "Learn more about: /FC (Full Path of Source Code File in Diagnostics)"
3-
title: "/FC (Full Path of Source Code File in Diagnostics)"
4-
ms.date: "11/04/2016"
5-
f1_keywords: ["VC.Project.VCCLCompilerTool.UseFullPaths", "/FC"]
2+
description: "Learn more about: /FC (Full path of source code file in diagnostics)"
3+
title: "/FC (Full path of source code file in diagnostics)"
4+
ms.date: 04/26/2021
5+
f1_keywords: ["VC.Project.VCCLCompilerTool.UseFullPaths", "/FC", "-FC"]
66
helpviewer_keywords: ["/FC compiler option [C++]", "-FC compiler option [C++]"]
77
ms.assetid: 1f11414e-cb42-421b-be68-9d369aab036b
88
---
9-
# /FC (Full Path of Source Code File in Diagnostics)
9+
# `/FC` (Full path of source code file in diagnostics)
1010

1111
Causes the compiler to display the full path of source code files passed to the compiler in diagnostics.
1212

1313
## Syntax
1414

15-
> /FC
15+
> **`/FC`**
1616
1717
## Remarks
1818

19-
Consider the following code sample:
19+
Consider the following code sample, where the source file is located in *`C:\test\compiler_option_FC.cpp`*:
2020

2121
```cpp
2222
// compiler_option_FC.cpp
23+
2324
int main( ) {
2425
int i // C2143
2526
}
2627
```
2728
28-
Without **/FC**, the diagnostic text would look similar to this diagnostic text:
29+
Without **`/FC`**, the compiler output looks similar to this diagnostic text:
30+
31+
- compiler_option_FC.cpp(5): error C2143: syntax error: missing ';' before '}'
32+
33+
With **`/FC`**, the compiler output looks similar to this diagnostic text:
34+
35+
::: moniker range="<=msvc-150"
36+
37+
- c:\test\compiler_option_fc.cpp(5): error C2143: syntax error: missing ';' before '}'
2938
30-
- compiler_option_FC.cpp(5) : error C2143: syntax error : missing ';' before '}'
39+
::: moniker-end
40+
::: moniker range="msvc-160"
3141
32-
With **/FC**, the diagnostic text would look similar to this diagnostic text:
42+
- C:\test\compiler_option_FC.cpp(5): error C2143: syntax error: missing ';' before '}'
3343
34-
- c:\test\compiler_option_fc.cpp(5) : error C2143: syntax error : missing ';' before '}'
44+
::: moniker-end
3545
36-
**/FC** is also needed if you want to see the full path of a file name when using the &#95;&#95;FILE&#95;&#95; macro. See [Predefined Macros](../../preprocessor/predefined-macros.md) for more information on &#95;&#95;FILE&#95;&#95;.
46+
**`/FC`** is also needed if you want to see the full path of a file name when using the `__FILE__` macro. For more information about `__FILE__`, see [Predefined macros](../../preprocessor/predefined-macros.md).
3747
38-
The **/FC** option is implied by **/ZI**. For more information about **/ZI**, see [/Z7, /Zi, /ZI (Debug Information Format)](z7-zi-zi-debug-information-format.md).
48+
The **`/FC`** option is implied by **`/ZI`**. For more information about **`/ZI`**, see [`/Z7, /Zi, /ZI` (Debug information format)](z7-zi-zi-debug-information-format.md).
3949
40-
**/FC** outputs full paths in lower case.
50+
In Visual Studio 2017 and earlier versions, **`/FC`** outputs full paths in lower case. Starting in Visual Studio 2019, **`/FC`** uses the same casing as the file system for full paths.
4151
4252
### To set this compiler option in the Visual Studio development environment
4353
@@ -47,11 +57,11 @@ The **/FC** option is implied by **/ZI**. For more information about **/ZI**, se
4757
4858
1. Modify the **Use Full Paths** property.
4959
50-
### To set this linker option programmatically
60+
### To set this compiler option programmatically
5161
5262
- See <xref:Microsoft.VisualStudio.VCProjectEngine.VCCLCompilerTool.UseFullPaths%2A>.
5363
5464
## See also
5565
56-
[MSVC Compiler Options](compiler-options.md)<br/>
57-
[MSVC Compiler Command-Line Syntax](compiler-command-line-syntax.md)
66+
[MSVC compiler options](compiler-options.md)\
67+
[MSVC compiler command-line syntax](compiler-command-line-syntax.md)

docs/build/reference/openmp-enable-openmp-2-0-support.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ Currently, the **`/openmp:llvm`** option only works on the x64 architecture. The
4141

4242
Applications compiled by using both **`/openmp`** and **`/clr`** can only be run in a single application domain process. Multiple application domains aren't supported. That is, when the module constructor (`.cctor`) is run, it detects if the process is compiled using **`/openmp`**, and if the app is loaded into a non-default runtime. For more information, see [`appdomain`](../../cpp/appdomain.md), [`/clr` (Common Language Runtime Compilation)](clr-common-language-runtime-compilation.md), and [Initialization of Mixed Assemblies](../../dotnet/initialization-of-mixed-assemblies.md).
4343

44-
If you attempt to load an app compiled using both **`/openmp`** and **`/clr*`* into a non-default application domain, a <xref:System.TypeInitializationException> exception is thrown outside the debugger, and a `OpenMPWithMultipleAppdomainsException` exception is thrown in the debugger.
44+
If you attempt to load an app compiled using both **`/openmp`** and **`/clr`** into a non-default application domain, a <xref:System.TypeInitializationException> exception is thrown outside the debugger, and a `OpenMPWithMultipleAppdomainsException` exception is thrown in the debugger.
4545

4646
These exceptions can also be raised in the following situations:
4747

docs/c-runtime-library/reference/splitpath-s-wsplitpath-s.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ Base filename (without extension). You can pass **NULL** for this parameter if y
8181
The size of the *fname* buffer in single-byte or wide characters. If *fname* is **NULL**, this value must be 0.
8282

8383
*ext*<br/>
84-
Filename extension, including leading period (**.**).You can pass **NULL** for this parameter if you do not need the filename extension.
84+
Filename extension, including leading period (**.**). You can pass **NULL** for this parameter if you do not need the filename extension.
8585

8686
*extNumberOfElements*<br/>
8787
The size of *ext* buffer in single-byte or wide characters. If *ext* is **NULL**, this value must be 0.

docs/code-quality/c6290.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ ms.assetid: 96a1acc4-724b-4b56-b091-661ddcc03884
1313
1414
This warning indicates possible confusion in the use of an operator or an operator precedence.
1515

16-
The `!` operator yields a Boolean result, and it has higher precedence than the `&`.The bitwise-and (&) operator takes two arithmetic arguments. Therefore, one of the following errors has been detected:
16+
The `!` operator yields a Boolean result, and it has higher precedence than the `&`. The bitwise-and (&) operator takes two arithmetic arguments. Therefore, one of the following errors has been detected:
1717

1818
- The expression is mis-parenthesised:
1919

docs/cpp/inheritance-cpp.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class Derived : [virtual] [access-specifier] Base1,
2727

2828
After the tag (name) for the class, a colon appears followed by a list of base specifications. The base classes so named must have been declared previously. The base specifications may contain an access specifier, which is one of the keywords **`public`**, **`protected`** or **`private`**. These access specifiers appear before the base class name and apply only to that base class. These specifiers control the derived class's permission to use to members of the base class. See [Member-Access Control](../cpp/member-access-control-cpp.md) for information on access to base class members. If the access specifier is omitted, the access to that base is considered **`private`**. The base specifications may contain the keyword **`virtual`** to indicate virtual inheritance. This keyword may appear before or after the access specifier, if any. If virtual inheritance is used, the base class is referred to as a virtual base class.
2929

30-
Multiple base classes can be specified, separated by commas. If a single base class is specified, the inheritance model is [Single inheritance](../cpp/single-inheritance.md).If more than one base class is specified, the inheritance model is called [Multiple inheritance](../cpp/multiple-base-classes.md).
30+
Multiple base classes can be specified, separated by commas. If a single base class is specified, the inheritance model is [Single inheritance](../cpp/single-inheritance.md). If more than one base class is specified, the inheritance model is called [Multiple inheritance](../cpp/multiple-base-classes.md).
3131

3232
The following topics are included:
3333

docs/cppcx/partial-classes-c-cx.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ The following code fragment demonstrates accessibility. In the first partial cla
4242

4343
A partial definition of a class such as `MyClass` is only a declaration of MyClass. That is, it only introduces the name `MyClass`. `MyClass` can't be used in a way that requires a class definition, for example, knowing the size of `MyClass` or using a base or member of `MyClass`. `MyClass` is considered to be defined only when the compiler encounters a non-partial definition of `MyClass`.
4444

45-
The following example demonstrates the declaration behavior of a partial class. After declaration #1, `MyClass` can be used as if it were written as the forward declaration, `ref class MyClass;`. Declaration #2 is equivalent to declaration #1.Declaration #3 is valid because it's a forward declaration to a class. But declaration #4 is invalid because
45+
The following example demonstrates the declaration behavior of a partial class. After declaration #1, `MyClass` can be used as if it were written as the forward declaration, `ref class MyClass;`. Declaration #2 is equivalent to declaration #1. Declaration #3 is valid because it's a forward declaration to a class. But declaration #4 is invalid because
4646

4747
`MyClass` is not fully defined.
4848

docs/error-messages/compiler-errors-1/compiler-error-c2139.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,18 @@
11
---
22
description: "Learn more about: Compiler Error C2139"
33
title: "Compiler Error C2139"
4-
ms.date: "11/04/2016"
4+
ms.date: 05/03/2021
55
f1_keywords: ["C2139"]
66
helpviewer_keywords: ["C2139"]
7-
ms.assetid: 31e047c0-5bf9-46c2-b6de-b627ea6a5768
87
---
98
# Compiler Error C2139
109

11-
'type' : an undefined class is not allowed as an argument to compiler intrinsic type trait 'trait'
10+
> '*type*' : an undefined class is not allowed as an argument to compiler intrinsic type trait '*trait*'
1211
1312
An invalid argument was passed to a type trait.
1413

14+
## Remarks
15+
1516
For more information, see [Compiler Support for Type Traits](../../extensions/compiler-support-for-type-traits-cpp-component-extensions.md).
1617

1718
## Example

docs/error-messages/compiler-errors-1/compiler-error-c2201.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,19 @@
11
---
22
description: "Learn more about: Compiler Error C2201"
33
title: "Compiler Error C2201"
4-
ms.date: "11/04/2016"
4+
ms.date: 05/03/2021
55
f1_keywords: ["C2201"]
66
helpviewer_keywords: ["C2201"]
7-
ms.assetid: ed927659-6e9c-447d-9963-19969ae1e957
87
---
98
# Compiler Error C2201
109

11-
'identifier' : must have external linkage in order to be exported/imported
10+
> '*identifier*' : must have external linkage in order to be exported/imported
1211
1312
The exported identifier is **`static`**.
1413

15-
The following sample generates C2286:
14+
## Example
15+
16+
The following sample generates C2286, and shows how to fix it:
1617

1718
```cpp
1819
// C2201.cpp

docs/error-messages/compiler-errors-2/compiler-error-c2668.md

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,18 @@
11
---
22
description: "Learn more about: Compiler Error C2668"
33
title: "Compiler Error C2668"
4-
ms.date: "03/28/2017"
4+
ms.date: 05/03/2021
55
f1_keywords: ["C2668"]
66
helpviewer_keywords: ["C2668"]
77
ms.assetid: 041e9627-1c76-420e-a653-cfc83f933bd3
88
---
99
# Compiler Error C2668
1010

11-
'function' : ambiguous call to overloaded function
11+
> 'function' : ambiguous call to overloaded function
1212
13-
The specified overloaded function call could not be resolved. You may want to explicitly cast one or more of the actual parameters.
13+
The specified overloaded function call couldn't be resolved. You may want to explicitly cast one or more of the actual parameters.
1414

15-
You can also get this error through template use. If, in the same class, you have a regular member function and a templated member function with the same signature, the templated one must come first. This is a limitation of the current implementation of Visual C++.
15+
You can also get this error through template use. If, in the same class, you have a regular member function and a templated member function with the same signature, the templated one must come first. This limitation remains in the current implementation of Visual C++.
1616

1717
## Examples
1818

@@ -34,7 +34,7 @@ int main() {
3434
}
3535
```
3636
37-
Another way to resolve this error is with a [using declaration](../../cpp/using-declaration.md):
37+
Another way to resolve this error is with a [`using` declaration](../../cpp/using-declaration.md):
3838
3939
```cpp
4040
// C2668b.cpp
@@ -75,9 +75,7 @@ class MyTestCase : public AppTestCase {
7575
};
7676
```
7777

78-
This error can also be generated as a result of compiler conformance work that was done for Visual Studio .NET 2003: ambiguous conversion on cast of constant 0.
79-
80-
Conversion on a cast using constant 0 is ambiguous since int requires a conversion both to long and to void*. To resolve this error, cast 0 to the exact type of the function parameter it is being used for so that no conversions need to take place (this code will be valid in the Visual Studio .NET 2003 and Visual Studio .NET versions of Visual C++).
78+
Conversion on a cast using constant 0 is ambiguous since **`int`** requires a conversion both to **`long`** and to `void*`. To resolve this error, cast 0 to the exact type of the function parameter it's being used for. Then no conversions need to take place.
8179

8280
```cpp
8381
// C2668c.cpp
@@ -97,7 +95,7 @@ int main() {
9795
}
9896
```
9997
100-
This error can occur because the CRT now has float and double forms of all math functions.
98+
This error can occur because the CRT now has **`float`** and **`double`** forms of all math functions.
10199
102100
```cpp
103101
// C2668d.cpp
@@ -110,7 +108,7 @@ int main() {
110108
}
111109
```
112110

113-
This error can occur because the pow(int, int) was removed from math.h in the CRT.
111+
This error can occur because the `pow(int, int)` was removed from *`math.h`* in the CRT.
114112

115113
```cpp
116114
// C2668e.cpp
@@ -121,7 +119,7 @@ int main() {
121119
}
122120
```
123121

124-
This code succeeds in Visual Studio 2015 but fails in Visual Studio 2017 and later with C2668. In Visual Studio 2015, the compiler erroneously treated copy-list-initialization in the same way as regular copy-initialization; it considered only converting constructors for overload resolution.
122+
This code succeeds in Visual Studio 2015 but fails in Visual Studio 2017 and later with C2668. In Visual Studio 2015, the compiler erroneously treated copy-list-initialization in the same way as regular copy-initialization. It considered only converting constructors for overload resolution.
125123

126124
```cpp
127125
struct A {
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
description: "Learn about the causes of Compiler error C7536 and how to fix it."
3+
title: "Compiler Error C7536"
4+
ms.date: 05/03/2021
5+
f1_keywords: ["C7536"]
6+
helpviewer_keywords: ["C7536"]
7+
---
8+
# Compiler Error C7536
9+
10+
> ifc failed integrity checks. Expected SHA2: '*hash-value*'
11+
12+
The compiler raises C7536 whenever the *`.ifc`* file has been tampered with. The header of the module interface contains an SHA2 hash of the contents below it. On import, the *`.ifc`* file is hashed, then checked against the hash provided in the header. If these don't match, error C7536 is raised:
13+
14+
```Output
15+
error C7536: ifc failed integrity checks.
16+
Expected SHA2: '66d5c8154df0c71d4cab7665bab4a125c7ce5cb9a401a4d8b461b706ddd771c6'
17+
```
18+
19+
This error is new in Visual Studio 2017 version 15.9. It's only generated when creating or consuming modules, specified by the `/experimental:module` compiler option.

0 commit comments

Comments
 (0)