Skip to content

Commit 672406c

Browse files
TaojunshenColin RobertsonTylerMSFTwmcnamaraTylerMSFT
authored
11/8/2021 AM Publish (#3888)
* draft * updates * draft content * Change incorrect link for logical AND This commit changes the link for logical AND from incorrectly linking to the bitwise AND to the correct logical AND. * draft * acrolinx and add to toc * rename existing file back to original filename * tech review * fix code sample (#3676) * fix code sample * acrolinx Co-authored-by: TylerMSFT <[email protected]> * Update fsanitize.md * Add mention in asan-building and add fsanitize-coverage options. * Expand /fsanitize=fuzzer description. Unify table format used on page. * Reference fsanitize-coverage.md in toc + full option lists. * Fix warnings * every relevant edge * Add OneFuzz mention * Fix mistaken deletion in chrono.md * Fpcontract docs (#3691) * Update fp-specify-floating-point-behavior.md Add details on /fp:contract flag * Update float-control.md Update float_control pragma behavior with respect to contractions. * small update * Update fenv-access.md * Update fp-contract.md * Update predefined-macros.md * fix typo and PR comments * leave definition of contractions * Add /fp:contract to the main list * fix line break * Add link to fp:contract * Add reference to fp:contract * Call out changes by compiler version. Co-authored-by: [email protected] <[email protected]> * Edit pass for i18n, grammar, and style * Respond to feedback * Add LibFuzzer link, consistency fixes * add new classes: ambiguous_local_time & nonexistent_local_time * acrolinx * fix links * finish descriptions * fix more links * smoothing out * proofing * add some better linking * tune description * update descriptions * needed to update local-info-struct.md to reflect changes to descriptions for nonexistent and ambiguous * add chrono functions * rounding out duration links * Add documentation for IntelliSense linter for C++ (#3821) * Add first draft of linter check documentation * WIP overview. Signed-off-by: Kyle Reed <[email protected]> * Update toc. First draft of the linter overview. * Add screenshots, move files, code samples are stand-alone. Signed-off-by: Kyle Reed <[email protected]> * Style and Acrolinx grammar checker pass * Add missing Options cues for checks * Update to use latest option names Co-authored-by: [email protected] <[email protected]> * connecting duration up to it's non-member pieces and doing some general updates * fix links * cleanup * Split out VS2019 content for linter (#3824) * Update working-with-project-properties.md * cleanup * cleanup * cleanup * cleanup * cleanup * cleanup * cleanup * fix function signature * fix line ending * remove duplicate * Address /profile issues per Paddy McD (#3834) * Fixed documentation that destroy dialogs * Update void-cpp for cpp-docs 3441 Reported in MicrosoftDocs/cpp-docs/issues/3441 Clarify kinds of class member where you can't use `void*`. Fix styles. Acrolinx a few things. * More clarity on void pointers to members * zoned_traits (#3831) * add zoned_traits * draft clock_cast and clock_time_conversion * first draft * draft * draft * fix heading * cleanup * add tzdb and tzdb-list * draft * draft * pull examples * draft cleanup * acrolinx * draft cleanup * draft cleanup * incorp tech review * tech review * cleanup * cleanup * acrolinx * fix casing * add example descriptions * wording * last adjustments * wording Co-authored-by: TylerMSFT <[email protected]> * Update 16.1 conformance per J Emmett * Update docs/error-messages/compiler-errors-2/compiler-error-c2666.md * draft * acrolinx, links * links * Fix typo in page title * acrolinx * fix link * Fix TOC schema before VS2022 changes * cleanup the port * add additional info * Address 3449 typo in /analyze * update see also * Address 3462 add C5033 warning * Include link update * Typo * Add TOC entry * Update how-to-marshal-callbacks-and-delegates-by-using-cpp-interop.md typo: underlaying -> underlying * Fix typo in toc for tzdb_list * fix github issue #3469 (#3852) Co-authored-by: TylerMSFT <[email protected]> * remove constexpr, prevent machine translation of code elements, and bring closer to current doc style (#3854) * remove constexpr * add remark * acrolinx * update casing * cleanup Co-authored-by: TylerMSFT <[email protected]> * VS2022 update for what's new content * Acrolinx update * Fix validation, links, typos * Revert a styling quirk on headers * Validation error fix * Acrolinx and validation fixes * Conformance fix updates * Adding missing intrinsic. * Fix intrinsic signature. * Fix wrong argument type. * Add headers, requirements * VS2022 features, C17, walkthroughs (#3863) * VS2022 features, C17, walkthroughs * fix indentation to correct list step numbering * fix indentation to correct list step numbering * replace numbers with bold headings Co-authored-by: Beth Harvey <[email protected]> * tech review feedback * cleanup * Frontrun bulk fixes for VS2022 * Fixes #3484 * Docs/corob/cpp docs 3481 d8049 (#3865) * Add D8049 error message * Acrolinx tweak * Update toc.yml fix apparent typo in TOC Co-authored-by: Jeff Borsecnik <[email protected]> * More VS2022 non-bulk fixes. (#3867) * Bulk update VS2022 content (#3860) * Bulk fix to update msvc-160 and msvc-170 * Fix stray moniker tags * incorp review * update wording around closing the folder * typos * fix typo introduced while fixing typos... * update formatting * update steps and formatting * Update working-with-resource-files.md * Update symbols-resource-identifiers.md * Update how-to-create-a-resource-script-file.md If you right click on a class you can't add resources. You should right click on a project. * started draft of STL conformance items * Update CMake landing page (#3864) * intro, installation, configure * config notifications * IDE integration * Building CMake projects * Debugging CMake projects * Open an existing cache * Edit CMakeLists.txt files * Configure IntelliSense * Troubleshooting, repro from CLI * Switch 17/19 CLI sections * edits * Fix code block * more edits * move images from docs/media to docs/build/media * Address feedback * Fix link style * Final edits * fix spelling per Acrolinx Co-authored-by: Beth Harvey <[email protected]> * finished first cut at VS 2022 17.0 STL conformance updates * Broken link fixed * move lwg-3518 to a c++11 section * De-emphasize codeplex archive * Add gray border (#3876) * tech review * remove LWG-* entries * Correct or remove links: validation issues * Update casting-c-cx.md * Update casting-c-cx.md * add vs 17.0 improvement summary for STL (#3883) * add vs 17.0 improvement summary for STL * wordsmithing * acrolinx * acrolinx * typo * fix caps * typo Co-authored-by: TylerMSFT <[email protected]> * update what's new in the docs (#3881) * add what's new for Oct 2021 * acrolinx * acrolinx * tidy up * update through date * tidy up * acrolinx * typo * Apply suggestions from PR review Co-authored-by: TylerMSFT <[email protected]> Co-authored-by: Shannon Leavitt <[email protected]> * change STL name * Update install for VS2022 * Remove Preview text Co-authored-by: Colin Robertson <[email protected]> Co-authored-by: TylerMSFT <[email protected]> Co-authored-by: Weston McNamara <[email protected]> Co-authored-by: Tyler Whitney <[email protected]> Co-authored-by: Steve Wishnousky <[email protected]> Co-authored-by: Gautham Beeraka <[email protected]> Co-authored-by: Kyle Reed <[email protected]> Co-authored-by: Chai Wei Jie <[email protected]> Co-authored-by: opbld15 <[email protected]> Co-authored-by: PRMerger19 <[email protected]> Co-authored-by: Laura Brenner <[email protected]> Co-authored-by: Courtney Wales <[email protected]> Co-authored-by: Andrea Courtright <[email protected]> Co-authored-by: PRMerger15 <[email protected]> Co-authored-by: opbld16 <[email protected]> Co-authored-by: PRMerger8 <[email protected]> Co-authored-by: Anju Del Moral Gonzalez <[email protected]> Co-authored-by: opbld17 <[email protected]> Co-authored-by: Miya Natsuhara <[email protected]> Co-authored-by: Kristine Toliver <[email protected]> Co-authored-by: PRMerger7 <[email protected]> Co-authored-by: Avraham <[email protected]> Co-authored-by: Paula Miller <[email protected]> Co-authored-by: Jose Rivero <[email protected]> Co-authored-by: Beth Harvey <[email protected]> Co-authored-by: PRMerger5 <[email protected]> Co-authored-by: Red Team Rover <[email protected]> Co-authored-by: Jeff Borsecnik <[email protected]> Co-authored-by: mohammad-ghasemi-2549 <[email protected]> Co-authored-by: Erika <[email protected]> Co-authored-by: Atik Mapari (Lionbridge Technologies Inc) <[email protected]> Co-authored-by: PRMerger Service account 2 <[email protected]> Co-authored-by: Jaiganesh Kumaran <[email protected]> Co-authored-by: PRMerger4 <[email protected]> Co-authored-by: Shannon Leavitt <[email protected]> Co-authored-by: PRMerger13 <[email protected]>
1 parent 6986944 commit 672406c

17 files changed

+589
-379
lines changed

.whatsnew.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"relativeLinkPrefix": "../"
88
},
99
"inclusionCriteria": {
10-
"minAdditionsToFile": 3,
10+
"minAdditionsToFile": 2,
1111
"pullRequestTitlesToIgnore": [
1212
"^Confirm merge from FromPublicMasterBranch",
1313
"^Repo sync for protected CLA branch"

docs/build/vscpp-step-0-installation.md

Lines changed: 105 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
title: Install C and C++ support in Visual Studio
33
description: "Learn how to install Visual Studio with support for Microsoft C/C++ and related workloads."
44
ms.custom: vs-acquisition, intro-installation
5-
ms.date: 11/05/2020
5+
ms.date: 11/08/2021
66
ms.topic: "tutorial"
77
ms.devlang: "cpp"
88
ms.assetid: 45138d70-719d-42dc-90d7-1d0ca31a2f54
@@ -11,6 +11,110 @@ ms.assetid: 45138d70-719d-42dc-90d7-1d0ca31a2f54
1111

1212
If you haven't downloaded and installed Visual Studio and the Microsoft C/C++ tools yet, here's how to get started.
1313

14+
::: moniker range="msvc-170"
15+
16+
## Visual Studio 2022 Installation
17+
18+
Welcome to Visual Studio 2022! In this version, it's easy to choose and install just the features you need. And because of its reduced minimum footprint, it installs quickly and with less system impact.
19+
20+
> [!NOTE]
21+
> This topic applies to installation of Visual Studio on Windows. [Visual Studio Code](https://code.visualstudio.com/) is a lightweight, cross-platform development environment that runs on Windows, Mac, and Linux systems. The Microsoft [C/C++ for Visual Studio Code](https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools) extension supports IntelliSense, debugging, code formatting, auto-completion. Visual Studio for Mac doesn't support Microsoft C++, but does support .NET languages and cross-platform development. For installation instructions, see [Install Visual Studio for Mac](/visualstudio/mac/installation/).
22+
23+
Want to know more about what else is new in this version? See the Visual Studio [release notes](/visualstudio/releases/2022/release-notes/).
24+
25+
Ready to install? We'll walk you through it, step-by-step.
26+
27+
### Step 1 - Make sure your computer is ready for Visual Studio
28+
29+
Before you begin installing Visual Studio:
30+
31+
1. Check the [system requirements](/visualstudio/releases/2022/system-requirements). These requirements help you know whether your computer supports Visual Studio 2022.
32+
33+
1. Apply the latest Windows updates. These updates ensure that your computer has both the latest security updates and the required system components for Visual Studio.
34+
35+
1. Reboot. The reboot ensures that any pending installs or updates don't hinder the Visual Studio install.
36+
37+
1. Free up space. Remove unneeded files and applications from your %SystemDrive% by, for example, running the Disk Cleanup app.
38+
39+
For questions about running previous versions of Visual Studio side by side with Visual Studio 2022, see the [Visual Studio 2022 Platform Targeting and Compatibility](/visualstudio/releases/2022/compatibility/) page.
40+
41+
### Step 2 - Download Visual Studio
42+
43+
Next, download the Visual Studio bootstrapper file. To do so, choose the following button to go to the Visual Studio download page. Select the edition of Visual Studio that you want and choose the **Free trial** or **Free download** button.
44+
45+
> [!div class="button"]
46+
> [Download Visual Studio](https://visualstudio.microsoft.com/downloads/)
47+
48+
### Step 3 - Install the Visual Studio installer
49+
50+
Run the bootstrapper file you downloaded to install the Visual Studio Installer. This new lightweight installer includes everything you need to both install and customize Visual Studio.
51+
52+
1. From your **Downloads** folder, double-click the bootstrapper that matches or is similar to one of the following files:
53+
54+
- **vs_community.exe** for Visual Studio Community
55+
- **vs_professional.exe** for Visual Studio Professional
56+
- **vs_enterprise.exe** for Visual Studio Enterprise
57+
58+
If you receive a User Account Control notice, choose **Yes** to allow the bootstrapper to run.
59+
60+
1. We'll ask you to acknowledge the Microsoft [License Terms](https://visualstudio.microsoft.com/license-terms/) and the Microsoft [Privacy Statement](https://privacy.microsoft.com/privacystatement). Choose **Continue**.
61+
62+
### Step 4 - Choose workloads
63+
64+
After the installer is installed, you can use it to customize your installation by selecting the *workloads*, or feature sets, that you want. Here's how.
65+
66+
1. Find the workload you want in the **Installing Visual Studio** screen.
67+
68+
![Visual Studio 2022: Install a workload.](../get-started/media/vs2022-installer-workloads.png)
69+
70+
For core C and C++ support, choose the "Desktop development with C++" workload. It comes with the default core editor, which includes basic code editing support for over 20 languages, the ability to open and edit code from any folder without requiring a project, and integrated source code control.
71+
72+
Additional workloads support other kinds of development. For example, choose the "Universal Windows Platform development" workload to create apps that use the Windows Runtime for the Microsoft Store. Choose "Game development with C++" to create games that use DirectX, Unreal, and Cocos2d. Choose "Linux development with C++" to target Linux platforms, including IoT development.
73+
74+
The **Installation details** pane lists the included and optional components installed by each workload. You can select or deselect optional components in this list. For example, to support development by using the Visual Studio 2017 or 2015 compiler toolsets, choose the MSVC v141 or MSVC v140 optional components. You can add support for MFC, the experimental Modules language extension, IncrediBuild, and more.
75+
76+
1. After you choose the workload(s) and optional components you want, choose **Install**.
77+
78+
Next, status screens appear that show the progress of your Visual Studio installation.
79+
80+
> [!TIP]
81+
> At any time after installation, you can install workloads or components that you didn't install initially. If you have Visual Studio open, go to **Tools** > **Get Tools and Features...** which opens the Visual Studio Installer. Or, open **Visual Studio Installer** from the Start menu. From there, you can choose the workloads or components that you wish to install. Then, choose **Modify**.
82+
83+
### Step 5 - Choose individual components (Optional)
84+
85+
If you don't want to use the Workloads feature to customize your Visual Studio installation, or you want to add more components than a workload installs, you can do so by installing or adding individual components from the **Individual components** tab. Choose what you want, and then follow the prompts.
86+
87+
### Step 6 - Install language packs (Optional)
88+
89+
By default, the installer program tries to match the language of the operating system when it runs for the first time. To install Visual Studio in a language of your choosing, choose the **Language packs** tab from the Visual Studio Installer, and then follow the prompts.
90+
91+
![Screenshot of the Visual Studio Installer, showing the Install language packs tab view.](../get-started/media/vs-installer-language-packs.png)
92+
93+
#### Change the installer language from the command line
94+
95+
Another way that you can change the default language is by running the installer from the command line. For example, you can force the installer to run in English by using the following command: `vs_installer.exe --locale en-US`. The installer will remember this setting when it's run the next time. The installer supports the following language tokens: zh-cn, zh-tw, cs-cz, en-us, es-es, fr-fr, de-de, it-it, ja-jp, ko-kr, pl-pl, pt-br, ru-ru, and tr-tr.
96+
97+
### Step 7 - Change the installation location (Optional)
98+
99+
You can reduce the installation footprint of Visual Studio on your system drive. You can choose to move the download cache, shared components, SDKs, and tools to different drives, and keep Visual Studio on the drive that runs it the fastest.
100+
101+
> [!IMPORTANT]
102+
> You can select a different drive only when you first install Visual Studio. If you've already installed it and want to change drives, you must uninstall Visual Studio and then reinstall it.
103+
104+
### Step 8 - Start developing
105+
106+
1. After Visual Studio installation is complete, choose the **Launch** button to get started developing with Visual Studio.
107+
108+
1. On the start window, choose **Create a new project**.
109+
110+
1. In the search box, enter the type of app you want to create to see a list of available templates. The list of templates depends on the workload(s) that you chose during installation. To see different templates, choose different workloads.
111+
112+
You can also filter your search for a specific programming language by using the **Language** drop-down list. You can filter by using the **Platform** list and the **Project type** list, too.
113+
114+
1. Visual Studio opens your new project, and you're ready to code!
115+
116+
::: moniker-end
117+
14118
::: moniker range="msvc-160"
15119

16120
## Visual Studio 2019 Installation

docs/cppcx/casting-c-cx.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ Use safe_cast if the code does not declare the relationship but you are sure tha
5050

5151
## dynamic_cast
5252

53-
Use **`dynamic_cast`** when you cast an object (more specifically, a hat **^**) to a more derived type, you expect either that the target object might sometimes be **`nullptr`** or that the cast might fail, and you want to handle that condition as a regular code path instead of an exception. For example, in the **Blank App (Universal Windows)** project template, the `OnLaunched` method in app.xamp.cpp uses **`dynamic_cast`** to test whether the app window has content. It's not an error if it doesn’t have content; it is an expected condition. `Windows::Current::Content` is a `Windows::UI::XAML::UIElement` and the conversion is to a `Windows::UI.XAML::Controls::Frame`, which is a more derived type in the inheritance hierarchy.
53+
Use **`dynamic_cast`** when you cast an object (more specifically, a hat **^**) to a more derived type, you expect either that the target object might sometimes be **`nullptr`** or that the cast might fail, and you want to handle that condition as a regular code path instead of an exception. For example, in the **Blank App (Universal Windows)** project template, the `OnLaunched` method in app.xaml.cpp uses **`dynamic_cast`** to test whether the app window has content. It's not an error if it doesn’t have content; it is an expected condition. `Windows::Current::Content` is a `Windows::UI::XAML::UIElement` and the conversion is to a `Windows::UI.XAML::Controls::Frame`, which is a more derived type in the inheritance hierarchy.
5454

5555
```cpp
5656
void App::OnLaunched(Windows::ApplicationModel::Activation::LaunchActivatedEventArgs^ args)
@@ -87,7 +87,7 @@ ComPtr<IInspectable> inspectable = reinterpret_cast<IInspectable*>(winRtObject);
8787
// ...
8888
```
8989

90-
If you use **`reinterpret_cast`** to convert from oneWindows Runtime interface to another, you cause the object to be released twice. Therefore, only use this cast when you are converting to a non-C++ component extensions interface.
90+
If you use **`reinterpret_cast`** to convert from one Windows Runtime interface to another, you cause the object to be released twice. Therefore, only use this cast when you are converting to a non-C++ component extensions interface.
9191

9292
## ABI types
9393

Loading
Loading

docs/get-started/tutorial-console-cpp.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@ The usual starting point for a C++ programmer is a "Hello, world!" application t
2121

2222
Visual Studio uses *projects* to organize the code for an app, and *solutions* to organize your projects. A project contains all the options, configurations, and rules used to build your apps. It also manages the relationship between all the project's files and any external files. To create your app, first, you'll create a new project and solution.
2323

24-
1. If you've just started Visual Studio, you'll see the Visual Studio 2019 dialog box. Choose **Create a new project** to get started.
24+
1. If you've just started Visual Studio, you'll see the Visual Studio Start dialog box. Choose **Create a new project** to get started.
2525

26-
![Screenshot of the Visual Studio 2019 initial dialog.](./media/calc-vs2019-initial-dialog.png "The Visual Studio 2019 initial dialog")
26+
![Screenshot of the Visual Studio 2022 initial dialog.](./media/calc-vs2022-initial-dialog.png)
2727

2828
Otherwise, on the menubar in Visual Studio, choose **File** > **New** > **Project**. The **Create a new project** window opens.
2929

docs/overview/cpp-conformance-improvements.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ Microsoft C/C++ in Visual Studio (MSVC) makes conformance improvements and bug f
1010

1111
This document lists the changes in Visual Studio 2022. For a guide to the changes in Visual Studio 2019, see [C++ conformance improvements in Visual Studio 2019](cpp-conformance-improvements-2019.md). For changes in Visual Studio 2017, see [C++ conformance improvements in Visual Studio 2017](cpp-conformance-improvements-2017.md). For a complete list of previous conformance improvements, see [Visual C++ What's New 2003 through 2015](../porting/visual-cpp-what-s-new-2003-through-2015.md).
1212

13-
## <a name="improvements_170_preview"></a> Conformance improvements in Visual Studio 2022 Preview and RC (version 17.0)
13+
## <a name="improvements_170_preview"></a> Conformance improvements in Visual Studio 2022 version 17.0
1414

15-
Visual Studio 2022 Preview and RC version 17.0 contains the following conformance improvements, bug fixes, and behavior changes in the Microsoft C++ compiler.
15+
Visual Studio 2022 version 17.0 contains the following conformance improvements, bug fixes, and behavior changes in the Microsoft C++ compiler.
1616

1717
### Warning on bitfield width for enumeration type
1818

docs/overview/toc.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@ items:
66
href: ../overview/visual-cpp-in-visual-studio.md
77
- name: Overview of C++ development in Visual Studio
88
href: ../overview/overview-of-cpp-development.md
9-
- name: What's new for C++ in Visual Studio 2022 Preview
9+
- name: What's new for C++ in Visual Studio 2022
1010
href: ../overview/what-s-new-for-visual-cpp-in-visual-studio.md
1111
- name: What's new for C++ in Visual Studio 2019
1212
href: ../overview/what-s-new-for-cpp-2019.md
1313
- name: What's new for C++ in Visual Studio 2017
1414
href: ../overview/what-s-new-for-cpp-2017.md
1515
- name: What's new for Microsoft C++ docs
1616
href: ../overview/whats-new-cpp-docs.md
17-
- name: C++ conformance improvements in Visual Studio 2022 Preview
17+
- name: C++ conformance improvements in Visual Studio 2022
1818
href: ../overview/cpp-conformance-improvements.md
1919
- name: C++ conformance improvements in Visual Studio 2019
2020
href: ../overview/cpp-conformance-improvements-2019.md

0 commit comments

Comments
 (0)