Many of our interfaces use IStream to interchange data.
Now MIDL generates a copy of the IStream interface in every TLB - which are translated into a different RCWs, so you can't use the IStream provided by one interface to pass the data to another interface defined in a different TLB since the interfaces RCWs refer to different IStream RCWs.
Also this makes it impossible to generate a generic Stream adapter since this would need to derive from all possible IStream definitions to work.
We currently solve this by disassembling the interop and replacing all references to an IStream with the System.Runtime.InteropServices.ComTypes.IStream, so this would be a perfect candidate to make it into TlbImp!
Since this problem applies to all types defined in System.Runtime.InteropServices.ComTypes they all should be translated properly by TlbImp.
No files are attached