What is a unified type system?

后端 未结 2 1505
你的背包
你的背包 2020-12-15 06:46

I\'ve read a comparison of C# and Java and the first thing on the list is \"Single-root (unified) type system\".

Can you describe what a single-root (unified) type s

2条回答
  •  没有蜡笔的小新
    2020-12-15 07:10

    This is actually not true of C# either, not all types derive from objects, just like 99.9% of them. There exist a couple of very strange types that cannot be turned into objects. The only officially supported one is pointers. There are 3 more unsupported one like TypedReference, RuntimeArgumentHandle and a third whose name escapes me. Those 3 types are used with interop with variable length methods in C++/C. I wouldn't worry about them too much.

提交回复
热议问题