Skip to content

Fix CS9336 pattern matching error for .NET 11 SDK#658

Draft
Copilot wants to merge 6 commits intodarc-main-a0c39e7e-160f-487f-ad7d-23dbc828ba05from
copilot/sub-pr-654
Draft

Fix CS9336 pattern matching error for .NET 11 SDK#658
Copilot wants to merge 6 commits intodarc-main-a0c39e7e-160f-487f-ad7d-23dbc828ba05from
copilot/sub-pr-654

Conversation

Copy link
Contributor

Copilot AI commented Feb 6, 2026

  • You've read the Contributor Guide and Code of Conduct.
  • You've included unit tests for your change, where applicable.
  • You've included inline docs for your change, where applicable.
  • There's an open issue for the PR that you are making. If you'd like to propose a new feature or change, please open an issue to discuss the change or find an existing issue.

PR Title
Fix CS9336 pattern matching error for .NET 11 SDK

PR Description

.NET 11 SDK rejects ambiguous pattern matching syntax. Fixed by adding parentheses to clarify precedence:

// Before - CS9336: The pattern is redundant
if (_state is not State.RaisingPreContent or State.RaisingPreHeader)

// After
if (_state is not (State.RaisingPreContent or State.RaisingPreHeader))

Changed file: src/Microsoft.AspNetCore.SystemWebAdapters.CoreServices/Features/HttpApplicationPreSendEventsResponseBodyFeature.cs:67


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: twsouthwick <583206+twsouthwick@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Feb 6, 2026

Just as a heads up, I was blocked by some firewall rules while working on your feedback. Expand below for details.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • 0t3vsblobprodcus362.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • 11vvsblobprodcus336.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • 2zrvsblobprodcus388.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • 37bvsblobprodcus311.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • 4myvsblobprodcus32.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • 7devsblobprodcus323.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • 80zvsblobprodcus35.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • 8xbvsblobprodcus382.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • 96bvsblobprodcus338.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • ajhvsblobprodcus363.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • bcnvsblobprodcus378.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • d0svsblobprodcus381.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • frdvsblobprodcus327.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • gbsvsblobprodcus365.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • gervsblobprodcus329.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • https://api.github.com/repos/dotnet/systemweb-adapters/commits/b3256576178915abe043f41800b56f96765d78a4/check-runs
    • Triggering command: /usr/bin/curl curl -s -H Accept: application/vnd.github.v3&#43;json REDACTED (http block)
  • i1qvsblobprodcus353.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • ibzvsblobprodcus369.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • imzvsblobprodcus368.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • jd4vsblobprodcus366.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • kh4vsblobprodcus325.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • kijvsblobprodcus387.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • kmuvsblobprodcus389.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • l49vsblobprodcus358.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • lylvsblobprodcus31.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • m8dvsblobprodcus37.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • mfjvsblobprodcus373.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • n3kvsblobprodcus335.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • ofvvsblobprodcus315.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • p2ovsblobprodcus312.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • pc2vsblobprodcus360.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • pkvvsblobprodcus321.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • rcxvsblobprodcus328.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • s4uvsblobprodcus326.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • s8mvsblobprodcus38.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • u3hvsblobprodcus371.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • u6ovsblobprodcus377.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • v53vsblobprodcus320.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • vb4vsblobprodcus33.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • vwvvsblobprodcus334.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)
  • xupvsblobprodcus332.vsblob.vsassets.io
    • Triggering command: /usr/bin/dotnet dotnet restore (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Copilot AI changed the title [WIP] Update dependencies from dotnet/arcade Add NuGet feeds for .NET 9/10/11 to fix arcade dependency update Feb 6, 2026
Copilot AI requested a review from twsouthwick February 6, 2026 20:22
Copilot AI and others added 3 commits February 6, 2026 20:30
Co-authored-by: twsouthwick <583206+twsouthwick@users.noreply.github.com>
Co-authored-by: twsouthwick <583206+twsouthwick@users.noreply.github.com>
Co-authored-by: twsouthwick <583206+twsouthwick@users.noreply.github.com>
Copilot AI changed the title Add NuGet feeds for .NET 9/10/11 to fix arcade dependency update Fix CS9336: Disambiguate pattern matching for .NET 11 SDK Feb 6, 2026
Co-authored-by: twsouthwick <583206+twsouthwick@users.noreply.github.com>
Copilot AI changed the title Fix CS9336: Disambiguate pattern matching for .NET 11 SDK Fix CS9336 pattern matching error for .NET 11 SDK Feb 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants