Describe the bug
Compiler throws errors and fails to build assemblies when trying to build ComicRackCE.
Related to C# 14.0 Enumerable.Reverse breaking change.
Exact Steps to Reproduce
VS 2022
- Have the latest VS 2022 installed (17.14.20)
- MSBuild version: 17.14.23.0
- Clone and try to build any branch
VS 2026
- Have the latest VS 2026 installed (11206.111)
- MSBuild version: 18.1.0.0
- Clone and try to build any branch
Screenshots

cYo.Common.Windows and ComicRack project errors get raised once these are fixed. See end for relevant lines of code.
As text
Severity Code Description Project File Line Suppression State
Error (active) CS1579 foreach statement cannot operate on variables of type 'void' because 'void' does not contain a public instance or extension definition for 'GetEnumerator' cYo.Common cYo.Common\Mathematics\Numeric.cs 261
Error (active) CS1936 Could not find an implementation of the query pattern for source type 'void'. 'Select' not found. cYo.Common.Presentation cYo.Common.Presentation\Panels\OverlayManager.cs 227
Error (active) CS1579 foreach statement cannot operate on variables of type 'void' because 'void' does not contain a public instance or extension definition for 'GetEnumerator' cYo.Common.Presentation cYo.Common.Presentation\Panels\OverlayPanel.cs 690
Version
VS 2022 17.14.20 + MSBuild 17.14.23.0
VS 2026 11206.111 + MSBuild 18.1.0.0
Additional context
Enumerable.Reverse
When using C# 14 or newer and targeting a .NET older than net10.0 or .NET Framework with System.Memory reference, there is a breaking change with Enumerable.Reverse and arrays.
Relevant lines of code
|
string[] array = message.Split('\n').Reverse().Take(messageLines) |
|
foreach (ComicBook item in source.Reverse()) |
|
foreach (ComicBook item in source.Reverse()) |
|
foreach (bool item in flags.Reverse()) |
|
foreach (ToolStripMenuItem item in array2.Reverse()) |
|
return (from op in panels.ToArray().Reverse() |
|
foreach (OverlayPanel item in panels.ToArray().Reverse()) |
Describe the bug
Compiler throws errors and fails to build assemblies when trying to build ComicRackCE.
Related to C# 14.0
Enumerable.Reversebreaking change.Exact Steps to Reproduce
VS 2022
VS 2026
Screenshots
cYo.Common.WindowsandComicRackproject errors get raised once these are fixed. See end for relevant lines of code.As text
Version
VS 2022 17.14.20 + MSBuild 17.14.23.0
VS 2026 11206.111 + MSBuild 18.1.0.0
Additional context
Enumerable.ReverseC# 14.0 has been out for a while; this only became a problem on upgrading to the latest VS 2022.
Bug might only impact those using VS 2022/2026 and with the .NET 10 SDK installed
Relevant lines of code
ComicRackCE/ComicRack/Dialogs/Splash.cs
Line 256 in 9cca27e
ComicRackCE/ComicRack/Views/ComicBrowserControl.cs
Line 1669 in 9cca27e
ComicRackCE/ComicRack/Views/ComicBrowserControl.cs
Line 1686 in 9cca27e
ComicRackCE/cYo.Common/Mathematics/Numeric.cs
Line 261 in 9cca27e
ComicRackCE/cYo.Common.Windows/Forms/TextBoxContextMenu.cs
Line 197 in 9cca27e
ComicRackCE/cYo.Common.Presentation/Panels/OverlayManager.cs
Line 226 in 9cca27e
ComicRackCE/cYo.Common.Presentation/Panels/OverlayPanel.cs
Line 690 in 9cca27e