jbevain / cecil

Cecil is a library to inspect, modify and create .NET programs and libraries.
MIT License
2.74k stars 624 forks source link

System.IndexOutOfRangeException: Index was outside the bounds of the array #884

Closed Alex-Dobrynin closed 1 year ago

Alex-Dobrynin commented 1 year ago

I get this exception, when trying to build .netstandard 2.1 c# 9 code image

BUT there is one nuance. this happens when I have a lot of methods in class or its subclasses, even if I override base class virtual method it can happen. when I remove many of them, the project can be build When I say a lot I mean ~20 together with base class methods and overrides

this happens only in debug configuration

UPD if I check this in project settings, project can be build image

jbevain commented 1 year ago

Hi,

Thanks for filing this. Unfortunately there's not much I can do without a repro here. Could you attach or send privately the assembly that is read with Cecil in the XamlCTask?