{"id":419800,"date":"2022-03-22T14:00:51","date_gmt":"2022-03-22T11:00:51","guid":{"rendered":"https:\/\/en.buradabiliyorum.com\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/"},"modified":"2022-03-22T14:00:51","modified_gmt":"2022-03-22T11:00:51","slug":"how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it","status":"publish","type":"post","link":"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/","title":{"rendered":"#How Will Parameter Null Checks Work In C# 11? \u2013 CloudSavvy IT"},"content":{"rendered":"<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_84 counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-6a28ce961e22d\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #dd3333;color:#dd3333\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #dd3333;color:#dd3333\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-6a28ce961e22d\" checked aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-1'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/#%E2%80%9CHow_Will_Parameter_Null_Checks_Work_In_C_11_%E2%80%93_CloudSavvy_IT%E2%80%9D\" >&#8220;How Will Parameter Null Checks Work In C# 11? \u2013 CloudSavvy IT&#8221;<\/a><ul class='ez-toc-list-level-2' ><li class='ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/#What_Is_Parameter_Null-Checking\" >What Is Parameter Null-Checking?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/#Parameter_Null-Checking_Syntax_In_C_11\" >Parameter Null-Checking Syntax In C# 11<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/#How_Does_It_Work\" >How Does It Work?<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/#Why_Is_It_Controversial\" >Why Is It Controversial?<\/a><ul class='ez-toc-list-level-3' ><li class='ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/#_Exists_On_The_Parameter_Name_Not_The_Type\" >!! Exists On The Parameter Name, Not The Type<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/#Parameter_Names_Shouldnt_Surface_Implementation_Details\" >Parameter Names Shouldn\u2019t Surface Implementation Details<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/#Compatibility_With_Null_Reference_Types\" >Compatibility With Null Reference Types<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/#Code_Generation_Might_Be_A_Bad_Idea\" >Code Generation Might Be A Bad Idea<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/buradabiliyorum.com\/en\/how-will-parameter-null-checks-work-in-c-11-cloudsavvy-it\/#Summary\" >Summary<\/a><\/li><\/ul><\/li><\/ul><\/nav><\/div>\n<h1><span class=\"ez-toc-section\" id=\"%E2%80%9CHow_Will_Parameter_Null_Checks_Work_In_C_11_%E2%80%93_CloudSavvy_IT%E2%80%9D\"><\/span>&#8220;How Will Parameter Null Checks Work In C# 11? \u2013 CloudSavvy IT&#8221;<span class=\"ez-toc-section-end\"><\/span><\/h1>\n<div id=\"article-content-area\">\n<figure style=\"width: 1200px\" class=\"wp-caption aligncenter\"><img loading=\"lazy\" decoding=\"async\" class=\"type:primaryImage size-full wp-image-15814\" data-pagespeed-lazy-srcset=\"https:\/\/www.cloudsavvyit.com\/p\/uploads\/2022\/03\/e4d1b8ce.jpg?width=398&amp;trim=1,1&amp;bg-color=000&amp;pad=1,1 400w, https:\/\/www.cloudsavvyit.com\/p\/uploads\/2022\/03\/e4d1b8ce.jpg?width=1198&amp;trim=1,1&amp;bg-color=000&amp;pad=1,1 1200w\" sizes=\"auto, 400w, 1200w\" data-pagespeed-lazy-src=\"https:\/\/www.cloudsavvyit.com\/p\/uploads\/2022\/03\/e4d1b8ce.jpg?width=1198&amp;trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Illustration showing the C# logo above a laptop\" width=\"1200\" height=\"675\" src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><figcaption class=\"wp-caption-text\"><span class=\"type:primaryImage imagecredit\"><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/www.shutterstock.com\/image-illustration\/programming-using-c-language-sharp-logo-2101261633\">Shutterstock.com\/PHOTOGRIN<\/a><\/span><\/figcaption><\/figure>\n<p>An <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/click.linksynergy.com\/deeplink?id=2QzUaswX1as&amp;mid=24542&amp;u1=csit\/15813&amp;murl=https%3A%2F%2Fdevblogs.microsoft.com%2Fdotnet%2Fearly-peek-at-csharp-11-features\">early preview<\/a> of select features to be included in this year\u2019s C# 11 release is now available as part of Visual Studio 2022 Update 1. The most contentious addition is integrated parameter null-checking support. This uses code generation to eliminate manual comparisons against <code>null<\/code>.<\/p>\n<p>In this article we\u2019ll explore the current state of the feature, the criticism leveled against it, and how it could change before the final release. The syntax and behaviors described here <a href=\"https:\/\/buradabiliyorum.com\/en\/category\/download-scripts-themes-apps\/\" data-internallinksmanager029f6b8e52c=\"9\" title=\"Download Scripts &amp; Themes &amp; Apps\" target=\"_blank\" rel=\"noopener\">app<\/a>ly to the current (March 2022) C# 11 preview and could change considerably before launch.<\/p>\n<h2 id=\"what-is-parameter-null-checking\"><span class=\"ez-toc-section\" id=\"What_Is_Parameter_Null-Checking\"><\/span>What Is Parameter Null-Checking?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>First let\u2019s clarify what we\u2019re talking about. C# parameters without <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/docs.microsoft.com\/en-us\/dotnet\/csharp\/nullable-references\">nullable reference types<\/a> accept <code>null<\/code> as a value irrespective of their actual type:<\/p>\n<div class=\"wp-geshi-highlight-wrap5\">\n<div class=\"wp-geshi-highlight-wrap4\">\n<div class=\"wp-geshi-highlight-wrap3\">\n<div class=\"wp-geshi-highlight-wrap2\">\n<div class=\"wp-geshi-highlight-wrap\">\n<div class=\"wp-geshi-highlight\">\n<div class=\"cs\">\n<pre class=\"de1\">private string hello(string name) {&#13;\n    return \"Hello \" + name;&#13;\n}&#13;\n\u00a0\n\/\/ This works&#13;\nhello(null);<\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<p>This behavior is often undesirable. In the example above, passing <code>null<\/code> would produce nonsensical output. To overcome this issue, it\u2019s common for developers to add their own <code>null<\/code>-checks at the top of methods:<\/p>\n<div class=\"wp-geshi-highlight-wrap5\">\n<div class=\"wp-geshi-highlight-wrap4\">\n<div class=\"wp-geshi-highlight-wrap3\">\n<div class=\"wp-geshi-highlight-wrap2\">\n<div class=\"wp-geshi-highlight-wrap\">\n<div class=\"wp-geshi-highlight\">\n<div class=\"cs\">\n<pre class=\"de1\">private string hello(string name) {&#13;\n\u00a0\n    if (name is null) {&#13;\n        throw new ArgumentNullException(nameof(name));&#13;\n    }&#13;\n\u00a0\n    return \"Hello \" + name;&#13;\n\u00a0\n}&#13;\n\u00a0\n\/\/ ArgumentNullException&#13;\nhello(null);<\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<p>This can create a lot of boilerplate code when a method has several non-nullable parameters.<\/p>\n<h2 id=\"parameter-null-checking-syntax-in-c-11\"><span class=\"ez-toc-section\" id=\"Parameter_Null-Checking_Syntax_In_C_11\"><\/span>Parameter Null-Checking Syntax In C# 11<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>C# 11 lets you condense the above example to the following code:<\/p>\n<div class=\"wp-geshi-highlight-wrap5\">\n<div class=\"wp-geshi-highlight-wrap4\">\n<div class=\"wp-geshi-highlight-wrap3\">\n<div class=\"wp-geshi-highlight-wrap2\">\n<div class=\"wp-geshi-highlight-wrap\">\n<div class=\"wp-geshi-highlight\">\n<div class=\"cs\">\n<pre class=\"de1\">private string hello(string name!!) {&#13;\n    return \"Hello \" + name;&#13;\n}&#13;\n\u00a0\n\/\/ ArgumentNullException&#13;\nhello(null);<\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<p>The special <code>!!<\/code> syntax after the parameter name has the same effect as a manual <code>if (... is null)<\/code> \/ <code>throw new ArgumentNullException(...)<\/code> block. An <code>ArgumentNullException<\/code> instance will be thrown if you pass <code>null<\/code> to a parameter that uses the syntax.<\/p>\n<p>When multiple parameters are marked as non-nullable, checks are executed in the as-written parameter order. The thrown exception will reference the first non-nullable parameter to receive <code>null<\/code> in the invocation.<\/p>\n<p>The syntax can be used with most kinds of parameter including those in <code>async<\/code> methods, iterators, and lambdas. It doesn\u2019t work with abstract method parameters, <code>extern<\/code> and delegate parameters, and interface methods that aren\u2019t a <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/docs.microsoft.com\/en-us\/dotnet\/csharp\/language-reference\/proposals\/csharp-8.0\/default-interface-methods\">Default Interface Method<\/a> (DIM).<\/p>\n<h2 id=\"how-does-it-work\"><span class=\"ez-toc-section\" id=\"How_Does_It_Work\"><\/span>How Does It Work?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>The new syntax is based on compiler code generation. The compiler creates the familiar <code>if (... is null)<\/code> \/ <code>throw new ArgumentNullException(...)<\/code> code as it processes your source files.<\/p>\n<p>The feature\u2019s not adding anything to C#\u2019s language capabilities. It\u2019s merely writing common userland code for you, offering a concise syntax that cuts down on repetitive source sections.<\/p>\n<p>The generated code is positioned at the top of each affected method. If the method is a constructor, the code will be executed ahead of class field initializations and any calls to the <code>this<\/code> and <code>base<\/code> constructors. This is the only practical difference compared to manually created null-check expressions.<\/p>\n<h2 id=\"why-is-it-controversial\"><span class=\"ez-toc-section\" id=\"Why_Is_It_Controversial\"><\/span>Why Is It Controversial?<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p><a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/click.linksynergy.com\/deeplink?id=2QzUaswX1as&amp;mid=24542&amp;u1=csit\/15813&amp;murl=https%3A%2F%2Fdevblogs.microsoft.com%2Fdotnet%2Fearly-peek-at-csharp-11-features\">Critics of<\/a> the proposal are concerned about the syntax (<code>!!<\/code> poorly communicates its meaning and effect), its presence <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/click.linksynergy.com\/deeplink?id=2QzUaswX1as&amp;mid=24542&amp;u1=csit\/15813&amp;murl=https%3A%2F%2Fdevblogs.microsoft.com%2Fdotnet%2Fearly-peek-at-csharp-11-features\/#comment-14837\">on the parameter name<\/a> instead of the type, and whether boilerplate code generation is within the remit of the C# language project. There are also debates over null checking\u2019s interactions with <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/docs.microsoft.com\/en-us\/dotnet\/csharp\/nullable-references\">nullable reference types<\/a>.<\/p>\n<p>Let\u2019s unpick some of these arguments and their implications.<\/p>\n<h3 id=\"exists-on-the-parameter-name-not-the-type\"><span class=\"ez-toc-section\" id=\"_Exists_On_The_Parameter_Name_Not_The_Type\"><\/span><code>!!<\/code> Exists On The Parameter Name, Not The Type<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Writing <code>string param!!<\/code> feels unnatural because you\u2019re apparently imbuing the parameter name with extra behavior, rather than the type. Yet this is entirely consistent with what\u2019s actually happening.<\/p>\n<p>Type checking is a compiler-level activity; parameter null checking generates <em>runtime<\/em> code that checks the <em>value<\/em> of the parameter. Hence it makes sense for the syntax to target the <em>parameter<\/em> instead of its <em>type<\/em>.<\/p>\n<h3 id=\"parameter-names-shouldnt-surface-implementation-details\"><span class=\"ez-toc-section\" id=\"Parameter_Names_Shouldnt_Surface_Implementation_Details\"><\/span>Parameter Names Shouldn\u2019t Surface Implementation Details<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Another complaint is that <code>param!!<\/code> communicates information about the method\u2019s implementation via its declaration. The syntax does not affect the method\u2019s signature, instead revealing aspects of its internals. This is unsatisfactory to many developers.<\/p>\n<p>One floated way of addressing the issue would be to provide parameter null-checking behavior as an attribute. This isn\u2019t what attributes are for though \u2013 they\u2019re plain metadata whereas null-checks generate runtime code. There is also precedent for the behavior of <code>!!<\/code> in other method declaration components: take <code>async<\/code>, which reveals its target to be asynchronous, and wires up an appropriate execution model for you.<\/p>\n<h3 id=\"compatibility-with-null-reference-types\"><span class=\"ez-toc-section\" id=\"Compatibility_With_Null_Reference_Types\"><\/span>Compatibility With Null Reference Types<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Parameter null checks and null reference types (NRTs) are compatible with each other. However you will see new compiler warnings if you combine <code>!!<\/code> with a nullable type:<\/p>\n<div class=\"wp-geshi-highlight-wrap5\">\n<div class=\"wp-geshi-highlight-wrap4\">\n<div class=\"wp-geshi-highlight-wrap3\">\n<div class=\"wp-geshi-highlight-wrap2\">\n<div class=\"wp-geshi-highlight-wrap\">\n<div class=\"wp-geshi-highlight\">\n<div class=\"cs\">\n<pre class=\"de1\">private string hello(string? name!!) {&#13;\n    \/\/ ...&#13;\n}<\/pre>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<p>In this example the <code>string?<\/code> type explicitly allows <code>null<\/code> while <code>name!!<\/code> rejects it at runtime. The compiler detects this contradictory condition and issues a warning:<\/p>\n<pre>CS8995 Nullable type 'string?' is null-checked and will throw if null.<\/pre>\n<p>Whether the two mechanisms are <em>conceptually<\/em> compatible is a different problem. Nullable reference types enforce a value can\u2019t be <code>null<\/code> at compile time. Parameter null-checks throw an exception when a value <em>is<\/em> null at runtime. In an ideal landscape, only the former would be necessary \u2013 all methods would use NRTs to indicate whether they can accept <code>null<\/code> and enforcement would be wholly handled by the compiler.<\/p>\n<p>Unfortunately the C# landscape isn\u2019t ideal. Nullable reference types are an opt-in feature which have not been universally adopted. It\u2019s not realistic to expect all existing code accumulated over the 20 years of the C# language to support NRTs. Parameter null-checks are a pragmatic way of bridging new code that predominantly uses NRTs with older libraries that may return <code>null<\/code> at runtime. They make sense where your methods could be handed <code>null<\/code> \u2013 so an NRT can\u2019t be used \u2013 by code that hasn\u2019t adopted the modern approach.<\/p>\n<p>It\u2019s a mistake to approach <code>param!!<\/code> as a way of signalling that the parameter shouldn\u2019t be passed <code>null<\/code> \u2013 that\u2019s the requirement that <code>string?<\/code> caters for. The presence of <code>!!<\/code> is only known to the compiler. It\u2019s there to raise an <code>ArgumentNullException<\/code> on your behalf.<\/p>\n<h3 id=\"code-generation-might-be-a-bad-idea\"><span class=\"ez-toc-section\" id=\"Code_Generation_Might_Be_A_Bad_Idea\"><\/span>Code Generation Might Be A Bad Idea<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>There are <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/click.linksynergy.com\/deeplink?id=2QzUaswX1as&amp;mid=24542&amp;u1=csit\/15813&amp;murl=https%3A%2F%2Fdevblogs.microsoft.com%2Fdotnet%2Fearly-peek-at-csharp-11-features\/#comment-14881\">some views that<\/a> automatically generating code to perform this function might be more trouble than it\u2019s worth. Although it could remove a lot of boilerplate, it may also cause unexpected behaviors and make it harder to reason about the program.<\/p>\n<p>Developers need to understand that <code>ArgumentNullException<\/code> instances can be thrown wherever <code>!!<\/code> is used. The exception is inflexible and cannot be changed, even in situations such as instance members where a <code>NullReferenceException<\/code> may be more appropriate. This has led some commenters to suggest that parameter null-checks in their current form shouldn\u2019t become part of C#.<\/p>\n<p>There\u2019s no direct answer to this problem. Evidently the C# development team has decided code generation will have a net positive benefit on the community by saving time and reducing repetitiveness. However it should be acknowledged that null-checks result in one-size-fits-all code being added to your project, creating the possibility of problems if that size is later proved incorrect.<\/p>\n<h2 id=\"summary\"><span class=\"ez-toc-section\" id=\"Summary\"><\/span>Summary<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Two characters have created a discussion that\u2019s still unfolding: as it stands, <code>param!!<\/code> is coming to C# as a way to generate <code>throw ArgumentNullException(...)<\/code> for you. Despite its potential for slimming down boilerplate code \u2013 over 20,000 explicit null-checks <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/click.linksynergy.com\/deeplink?id=2QzUaswX1as&amp;mid=24542&amp;u1=csit\/15813&amp;murl=https%3A%2F%2Fdevblogs.microsoft.com%2Fdotnet%2Fearly-peek-at-csharp-11-features\/#notes-on-design\">have been removed from<\/a> .NET Runtime using the syntax \u2013 there remain a number of lingering doubts and concerns.<\/p>\n<p>We\u2019ve dissected the most prominent of these above and seen that most of the complaints are unfounded and based on misunderstandings. Arguably the biggest criticism surrounds the syntax itself, with <code>!!<\/code> viewed as opaque, difficult to discover, and inaccessible to newcomers. There are various proposals to replace it with something more obvious; <code>string param notnull<\/code> is gaining considerable attention, so the final form may look different when C# 11 arrives.<\/p>\n<p>You can have your say on the proposal by contributing to its <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/github.com\/dotnet\/csharplang\/discussions\/5735\">discussion thread<\/a> on GitHub. If you want to try out the current preview for yourself, you\u2019ll need Visual Studio 17.1 (2022 Update 1) and .NET SDK 6.0.200. You\u2019ll then need to change <code>LangVersion<\/code> to <code>preview<\/code> within your <code>.csproj<\/code> file to enable C# 11 support.\n<\/div>\n<blockquote><p><strong><span style=\"color: #ff6600;\">If you liked the article, do not forget to share it with your friends. Follow us on\u00a0<span style=\"color: #ff0000;\"><a style=\"color: #ff0000;\" href=\"https:\/\/news.google.com\/publications\/CAAqBwgKMLG0nwswvr63Aw\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">Google News<\/a><\/span>\u00a0too, click on the star and choose us from your favorites.<\/span><\/strong><\/p><\/blockquote>\n<blockquote>\n<p style=\"text-align: center;\">For forums sites go to <span style=\"color: #ff9900;\"><a style=\"color: #ff9900;\" href=\"https:\/\/forum.buradabiliyorum.com\/\" target=\"_blank\" rel=\"noopener\">Forum.BuradaBiliyorum.Com<\/a><\/span><\/strong><\/p>\n<\/blockquote>\n<blockquote>\n<p style=\"text-align: center;\"><strong>If you want to read more like this article, you can visit our <span style=\"color: #ff9900;\"><a style=\"color: #ff9900;\" href=\"https:\/\/en.buradabiliyorum.com\/technology\/\" target=\"_blank\" rel=\"noopener\">Technology category.<\/a><\/span><\/strong><\/p>\n<\/blockquote>\n<p><span style=\"color: black;\"><a style=\"color: #ff9900;\" href=\"https:\/\/www.cloudsavvyit.com\/15813\/how-will-parameter-null-checks-work-in-c-11\/\" target=\"_blank\" rel=\"noopener\">Source<\/a><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&#8220;How Will Parameter Null Checks Work In C# 11? \u2013 CloudSavvy IT&#8221; Shutterstock.com\/PHOTOGRIN An early preview of select features to be included in this year\u2019s C# 11 release is now available as part of Visual Studio 2022 Update 1. The most contentious addition is integrated parameter null-checking support. This uses code generation to eliminate manual&#8230;<\/p>\n","protected":false},"author":1,"featured_media":419801,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"fifu_image_url":"https:\/\/www.cloudsavvyit.com\/p\/uploads\/2022\/03\/e4d1b8ce.jpg","fifu_image_alt":"","footnotes":""},"categories":[18],"tags":[],"class_list":["post-419800","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-technology"],"_links":{"self":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts\/419800","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/comments?post=419800"}],"version-history":[{"count":0,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts\/419800\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/media\/419801"}],"wp:attachment":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/media?parent=419800"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/categories?post=419800"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/tags?post=419800"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}