From ab5febfba5b732e59d63f7818a475efcf5087839 Mon Sep 17 00:00:00 2001 From: Sebastian Przyszlak Date: Thu, 5 Nov 2026 11:12:23 +0000 Subject: [PATCH 1/5] Set C# language version to preview --- src/DotMaybe/DotMaybe.csproj | 1 + 1 file changed, 1 insertion(+) diff --git a/src/DotMaybe/DotMaybe.csproj b/src/DotMaybe/DotMaybe.csproj index ec5318c..c860897 100644 --- a/src/DotMaybe/DotMaybe.csproj +++ b/src/DotMaybe/DotMaybe.csproj @@ -1,6 +1,7 @@ + preview DotMaybe DotMaybe true From 989019fac20bb6cd8ea26e5c35a8e58cc0c04108 Mon Sep 17 00:00:00 2001 From: Sebastian Przyszlak Date: Thu, 5 Nov 2026 12:55:14 +0000 Subject: [PATCH 2/5] Update SDK version in global.json --- global.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/global.json b/global.json index 62939fe..76c91f5 100644 --- a/global.json +++ b/global.json @@ -1,6 +1,6 @@ { "sdk": { - "version": "11.0.100-rc.1.26425.128", + "version": "11.0.100-rc.2.26504.105", "rollForward": "latestFeature", "allowPrerelease": true }, From 134d76376b9212635e3341f9dee9a5f8f8f995f3 Mon Sep 17 00:00:00 2001 From: Sebastian Przyszlak Date: Thu, 5 Nov 2026 12:57:06 +0000 Subject: [PATCH 3/5] Update SDK version in global.json --- global.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/global.json b/global.json index 76c91f5..7903a71 100644 --- a/global.json +++ b/global.json @@ -1,6 +1,6 @@ { "sdk": { - "version": "11.0.100-rc.2.26504.105", + "version": "11.0.100-rc.3.26522.148", "rollForward": "latestFeature", "allowPrerelease": true }, From e7581eb44d5508905fa5d176733c2562bfa4c7e3 Mon Sep 17 00:00:00 2001 From: frognar Date: Thu, 5 Nov 2026 14:15:18 +0100 Subject: [PATCH 4/5] chore: update ILLink tasks to rc.3 --- src/DotMaybe/packages.lock.json | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/DotMaybe/packages.lock.json b/src/DotMaybe/packages.lock.json index c883262..43d8683 100644 --- a/src/DotMaybe/packages.lock.json +++ b/src/DotMaybe/packages.lock.json @@ -10,9 +10,9 @@ }, "Microsoft.NET.ILLink.Tasks": { "type": "Direct", - "requested": "[11.0.0-rc.1.26425.128, )", - "resolved": "11.0.0-rc.1.26425.128", - "contentHash": "oMgihfjNcxZpR9B/O5Ke8Qmr8CJcpdzG4PnVYtA6Ja4g41NELxLRuiqqh5ys7w+ourEBNng2IIZnrlMJXfncmQ==" + "requested": "[11.0.0-rc.3.26522.148, )", + "resolved": "11.0.0-rc.3.26522.148", + "contentHash": "SWnTMx96mhBr9LCOySJg1ETlEFFHVsPGdVT02JnYhtqk1+Vke1J7RU3VkKwEiErBr4FJ42Uu4k7GdOtkRuvs/Q==" }, "MinVer": { "type": "Direct", From 40fdff000435d104bcda3b78ada8948f63407d2c Mon Sep 17 00:00:00 2001 From: frognar Date: Thu, 5 Nov 2026 14:28:06 +0100 Subject: [PATCH 5/5] chore: remove obsolete type parameter pattern contract --- .../PatternMatchingContracts.cs | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/tests/DotMaybe.CompilerContractTests/PatternMatchingContracts.cs b/tests/DotMaybe.CompilerContractTests/PatternMatchingContracts.cs index d53a98c..45c6608 100644 --- a/tests/DotMaybe.CompilerContractTests/PatternMatchingContracts.cs +++ b/tests/DotMaybe.CompilerContractTests/PatternMatchingContracts.cs @@ -48,21 +48,6 @@ public static string Describe(Maybe maybe) ContractAssert.CompilesCleanly(result); } - [Fact] - public void A_type_parameter_pattern_cannot_declare_a_variable() - { - // Found in TP-01 on SDK RC1: in generic code T could itself be a union, so the compiler cannot tell whether - // `T value` applies to the maybe or to its content, and rejects the declaration (CS8780). - // Generic code reads the value through Match (TP-02) instead. If a later compiler lifts the restriction, - // this contract turns red and we can simplify generic code. - var result = Snippet.Compile(Consumer.File(""" - public static string Describe(Maybe maybe) - where T : notnull => maybe is T value ? "some" : "none"; - """)); - - ContractAssert.FailsWith(result, "CS8780"); - } - [Fact] public void A_concrete_type_pattern_declares_a_variable() {