Skip to content
This repository was archived by the owner on Nov 1, 2020. It is now read-only.
This repository was archived by the owner on Nov 1, 2020. It is now read-only.

COM Interop Guidance #4219

Open
Open
@wjk

Description

@wjk

I am considering using CoreRT with my .NET Core compatible GUI framework. However, to fully implement the GUI feature support I require, I will need to do some COM interop. Having studied the CoreRT source code, I can tell that COM support is not currently implemented. To make this usable, here is what I would do:

  1. Redirect creation of ComImportAttribute-decorated types to CoCreateInstance. Wrap the return value of that P/Invoke into something like this.
  2. Redirect calls to methods of ComImportAttribute-decorated interfaces to code that takes the slot number of the method called, gets the corresponding vtable entry and performs a calli.

The problem is, though, this is not compatible in the slightest with the extensive but nonfunctional COM interop code already in the CoreRT repo. This COM interop code is only partially open-source (it references .NET Native functionality, as well as the MCG tool which is still proprietary), and is entirely WinRT-specific on top of that. Modifying the existing COM interop code to be compatible with desktop-style COM is currently far above my pay grade. Could anyone please give some pointers on how I or others might start working on implementing this? Thanks so much!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions