Can you compile C# so it doesn't need the .NET Framework at runtime?

前端 未结 8 1453
暖寄归人
暖寄归人 2020-11-28 08:53

Is it possible to force the C# compiler to pull all the referenced calls out of the framework and pack them into dlls or even a single executable?

I like writing qu

8条回答
  •  执笔经年
    2020-11-28 09:06

    Some C# features are bound to interfaces of the .NET framework.

    For example:

    yield return requires the IEnumerable interface

    using (x) {} requires the IDisposable interface

提交回复
热议问题