kevin-montrose / Sigil

A fail-fast validating helper for .NET CIL generation
Microsoft Public License
988 stars 92 forks source link

For review: fix issue 53 by fiddling with assignability check #54

Open benjamin-hodgson opened 7 years ago

benjamin-hodgson commented 7 years ago

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 don't know if this is the most effective way of fixing the bug, although the tests do all pass. Have a look at my code, feedback very welcome 😉