Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The reason it's more complicated is to support reflection. C# allows you to create objects and call methods at runtime based on data not available at compile time, including classes and methods that don't get used by the normal (non-reflection) code.

That means that by default you can't do tree shaking, which means you would end up with enormous exes, which will probably annoy the type of people who want a single exe.

The bit more advanced is to tell the compiler which types you might want to reference by reflection so that it can shake the rest out of the tree.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: