Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>The underlying WinRT interface is COM based. Every WinRT interface derives from IUnknown, its AddRef and Release methods implement reference count based memory management.</p> <p>This is however very well hidden, when you program a WinRT app then you use a language projection. For .NET and Javascript apps, the language projection is built into, respectively, the CLR and the Chakra engine. Which complete hide the implementation details, the WinRT interfaces are mapped to native language constructs. Including skillfully creating the illusion that COM supports generics and implementation inheritance. A somewhat reasonable guess is that the CLR projection uses COM interop support already built into the CLR but it is impossible to reverse-engineer this easily. If that's accurate at all then finalizers are likely to make the IUnknown::Release() call.</p> <p>Right now it is very hard to get decent info about the low-level details, the Microsoft bloggers and SO posters are not talking, source code is not available and questions that touch on the subject are getting closed, like <a href="https://stackoverflow.com/questions/7457371/why-is-winrt-unmanaged">this one</a>.</p> <p>As you can tell from Chen's comment to that question, you are not supposed to be curious about it. If you are worried then consider programming in C++/CX. Which does a good job of hiding the glue. Or native C++ with the WRL library, which doesn't. Both runtime environments where memory management is explicit. Microsoft invested a lot of resources in making C++ programming relevant again.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload