private ComPointer(IntPtr pUnk, bool addRef) { var refCount = -1; _pUnk = pUnk; if (addRef) { _addRef = true; refCount = RdMarshal.AddRef(_pUnk); } Interface = (TComInterface)RdMarshal.GetTypedObjectForIUnknown(pUnk, typeof(TComInterface)); ConstructorPointerPrint(refCount); }