Open a .NET 8 assembly, such as System.Private.CoreLib
View ReadyToRun code
Error message shown
System.BadImageFormatException: Warning: Invalid ReadyToRun section type
at ILCompiler.Reflection.ReadyToRun.ReadyToRunCoreHeader.ParseCoreHeader(Byte[] image, Int32& curOffset)
at ILCompiler.Reflection.ReadyToRun.ReadyToRunHeader..ctor(Byte[] image, Int32 rva, Int32 curOffset)
at ILCompiler.Reflection.ReadyToRun.ReadyToRunReader.EnsureHeader()
at ICSharpCode.ILSpy.ReadyToRun.ReadyToRunLanguage.DecompileMethod(IMethod method, ITextOutput output, DecompilationOptions options)
at ICSharpCode.ILSpy.TextView.DecompilerTextView.DecompileNodes(DecompilationContext context, ITextOutput textOutput)
at ICSharpCode.ILSpy.TextView.DecompilerTextView.<>c__DisplayClass51_0.<DecompileAsync>b__0()
Steps to reproduce
Error message shown
Details
See also #2784