Sigil
Sigil copied to clipboard
A fail-fast validating helper for .NET CIL generation
The C# compiler itself, when initializing a local, loads the address of the local, constructor arguments and then calls the constructor directly instead of using `newobj`. When attempting to do...
The problem was as follows: - `Emit.BuildInstanceMethod()` implicitly adds `this` to the list of expected parameters - `Emit.Call(Emit method, ...)` also adds implicit `this` - validation fails as it now...
Hi, I had problem packing a project that uses Sigil 5.0.0, got an error: "The DateTimeOffset specified cannot be converted into a Zip file timestamp" This is a [known issue...
Can it be used in Portable Class Library for .Net Framework and Xamarin Android?
Repro is to deploy a console application that does an `Assembly.Load("Sigil")` and publish it as self contained. It will fail stating it can't find the `PInvoke` assembly. It happened for...
While working with Sigil I noticed that LoadConstant is missing a overload that takes a ConstructorInfo, I used to do this using the raw ILGenerator and it work. So I...
I was hitting an issue where dynamic methods created with `doVerify` set to true work, while the same emitted instructions throw an `InvalidProgramException` when `doVerify` is set to false. After...
This fixes #53. The `IsAssignableFrom` method wasn't accounting for the fact that you can assign a (boxed) struct to an interface. I'm not very familiar with the codebase, so I...
Found this while debugging https://github.com/kevin-montrose/Jil/issues/257. (Jil emits virtual calls to `IEnumerable.GetEnumerator`.) ```csharp public struct MyStruct { } string Example(MyStruct s) => s.ToString(); ``` Looking at the above method in dotPeek,...
Hi, The function Sigil.NonGeneric.Emit.Call ends up calling this overload of Emit.Call: `public Emit Call(MethodInfo method, Type[] arglist = null)` That overload is for already builded types and, in fact, the...