What's new with Visual Studio 2022 17.1

Опубликовано: 15 Июнь 2026
на канале: Soner Gönül
1,642
29

Visual Studio 17.1 was released on February 15, 2022. In this video, we take a look at the new features introduced with this version.

#visualstudio #visualstudio2022

-- Faster searching with indexed files has been added. This feature is now available with the ServiceHub.IndexingService.exe application, which you can see in the background in the Task Manager. You can enable or disable this feature by going to Tools -- Options -- Environment -- Preview Features -- Enable indexing for a faster find experience.

-- Automatic synchronization of your code files. This feature can be enabled or disabled by going to Tools -- Options -- Environment -- Documents -- Automatically save files when Visual Studio is in the background. I don't think it's available in the Community Edition; it seems this is only available in professional and enterprise customers.

-- Comparison between branches.

-- Automatic conversion of regular or verbatim string literals to the "Raw string literal" feature, planned for C# 11, using the "Quick Tips" bubble.

So;

var s = "\"foo\r\nbar\"";

string

var s2 = """
"foo
bar"
""";

can do it.

Raw string literals support string interpolation and, as far as I can see, they don't care about alignment.

-- Line staging

It seems to be still under development. I think it's the process of staging a specific line within a file.

-- C# 7 - Tuple swap

var temp = args[1];
args[1] = args[0];
args[0] = temp;

You can convert the code to

(args[0], args[1]) = (args[1], args[0]);

with "Quick Actions".

-- Display diagnostics inline

You can access this feature using Tools -- Options -- Text Editor -- C# -- Advanced. It can directly display warnings that you might see with a popup.

For example, when you simply type:

int second = 1;

, it can directly print the popup that appears when you hover over the variable. It's currently in the testing phase.

-- Simplify property pattern

You can automatically convert the extended property patterns introduced in C# 10 with the "Quick Tips" bubble.

So, we can convert the code:

if (t is { Assembly: { EntryPoint: { CallingConvention: CallingConventions.Any } } }) ;

to

if (t is { Assembly.EntryPoint.CallingConvention: CallingConventions.Any }) ;

.

Sources:

https://devblogs.microsoft.com/visual...

https://docs.microsoft.com/en-us/visu...

https://github.com/dotnet/csharplang/...

***

Social Media

🐦 Follow us on Twitter:   / sonergonul  
💜 Follow us on Twitch:   / sonergonul  
💚 Our Discord channel:   / discord  
💖 Follow us on Quora: https://www.quora.com/profile/Soner-G...
💛 Follow on Instagram:   / sonergonul  

Support

💪 ByNoGame: https://www.bynogame.com/destekle/son...
💪 Stremlabs: https://streamlabs.com/sonergonul/tip