C# / .Net will have the same issue, but when they developed native compilation for windows phone apps they added a concept of a runtime definition file that lets you control how much needs to be retained for reflection: http://msdn.microsoft.com/en-us/library/dn600639%28v=vs.110%...
The native compilation technology is moving over to normal .Net and I would imagine the runtime definition file could be used for javascript transpiling tree-shaking as well.